Properly search for users when limittogroups is enabled
Searching just for the uid is not enough. This makes sure this done properly again now. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
parent
6e4b089265
commit
51922caa5f
|
@ -95,7 +95,15 @@ class UserPlugin implements ISearchPlugin {
|
|||
$usersInGroup = $this->groupManager->displayNamesInGroup($userGroupId, $search, $limit, $offset);
|
||||
foreach ($usersInGroup as $userId => $displayName) {
|
||||
$userId = (string) $userId;
|
||||
$users[$userId] = $this->userManager->get($userId);
|
||||
$user = $this->userManager->get($userId);
|
||||
if (!$user->isEnabled()) {
|
||||
// Ignore disabled users
|
||||
continue;
|
||||
}
|
||||
$users[$userId] = $user;
|
||||
}
|
||||
if (count($usersInGroup) >= $limit) {
|
||||
$hasMoreResults = true;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue