Skip to content

Commit 7aaf5fa

Browse files
blizzzbackportbot[bot]
authored andcommitted
simplify getGroups, fixing wrong chunking logic
pagination is taken care of properly in the search logic in Access class Signed-off-by: Arthur Schiwon <[email protected]>
1 parent c7c7433 commit 7aaf5fa

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

apps/user_ldap/lib/Group_LDAP.php

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1002,14 +1002,17 @@ public function countUsersInGroup($gid, $search = '') {
10021002
}
10031003

10041004
/**
1005-
* get a list of all groups
1005+
* get a list of all groups using a paged search
10061006
*
10071007
* @param string $search
1008-
* @param $limit
1008+
* @param int $limit
10091009
* @param int $offset
10101010
* @return array with group names
10111011
*
1012-
* Returns a list with all groups (used by getGroups)
1012+
* Returns a list with all groups
1013+
* Uses a paged search if available to override a
1014+
* server side search limit.
1015+
* (active directory has a limit of 1000 by default)
10131016
*/
10141017
protected function getGroupsChunk($search = '', $limit = -1, $offset = 0) {
10151018
if(!$this->enabled) {

0 commit comments

Comments
 (0)