diff options
author | Arthur Schiwon <blizzz@owncloud.com> | 2014-08-29 15:17:37 +0200 |
---|---|---|
committer | Arthur Schiwon <blizzz@owncloud.com> | 2014-08-29 15:17:37 +0200 |
commit | 0bb460c9b506593d04480c7b15278b2992aefa23 (patch) | |
tree | b6b0c2c30286cd538ecd55ec636cb4681e6ada9c /lib/private/group | |
parent | 033b0361edb206ac3c8303a0d8003fd6752d6f75 (diff) | |
download | nextcloud-server-0bb460c9b506593d04480c7b15278b2992aefa23.tar.gz nextcloud-server-0bb460c9b506593d04480c7b15278b2992aefa23.zip |
retrieve local users, groups and group members in a sorted way
Diffstat (limited to 'lib/private/group')
-rw-r--r-- | lib/private/group/database.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/private/group/database.php b/lib/private/group/database.php index 8d6ea1f50a5..e6a5565b20e 100644 --- a/lib/private/group/database.php +++ b/lib/private/group/database.php @@ -168,7 +168,7 @@ class OC_Group_Database extends OC_Group_Backend { * Returns a list with all groups */ public function getGroups($search = '', $limit = null, $offset = null) { - $stmt = OC_DB::prepare('SELECT `gid` FROM `*PREFIX*groups` WHERE `gid` LIKE ?', $limit, $offset); + $stmt = OC_DB::prepare('SELECT `gid` FROM `*PREFIX*groups` WHERE `gid` LIKE ? ORDER BY `gid` ASC', $limit, $offset); $result = $stmt->execute(array('%' . $search . '%')); $groups = array(); while ($row = $result->fetchRow()) { @@ -200,7 +200,7 @@ class OC_Group_Database extends OC_Group_Backend { * @return array an array of user ids */ public function usersInGroup($gid, $search = '', $limit = null, $offset = null) { - $stmt = OC_DB::prepare('SELECT `uid` FROM `*PREFIX*group_user` WHERE `gid` = ? AND `uid` LIKE ?', + $stmt = OC_DB::prepare('SELECT `uid` FROM `*PREFIX*group_user` WHERE `gid` = ? AND `uid` LIKE ? ORDER BY `uid` ASC', $limit, $offset); $result = $stmt->execute(array($gid, '%'.$search.'%')); |