Skip to content

Commit

Permalink
Fix #4789: Group admins cannot see disabled users
Browse files Browse the repository at this point in the history
  • Loading branch information
Neraste committed Nov 26, 2017
1 parent 63d9857 commit 2622dda
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions settings/Controller/UsersController.php
Original file line number Diff line number Diff line change
Expand Up @@ -339,16 +339,16 @@ public function index($offset = 0, $limit = 10, $gid = '', $pattern = '', $backe

// Batch all groups the user is subadmin of when a group is specified
$batch = [];
if ($gid === '') {
if ($gid !== '' && $gid !== '_disabledUsers' && $gid !== '_everyone') {
$batch = $this->groupManager->displayNamesInGroup($gid, $pattern, $limit, $offset);
} else {
foreach ($subAdminOfGroups as $group) {
$groupUsers = $this->groupManager->displayNamesInGroup($group, $pattern, $limit, $offset);

foreach ($groupUsers as $uid => $displayName) {
$batch[$uid] = $displayName;
}
}
} else {
$batch = $this->groupManager->displayNamesInGroup($gid, $pattern, $limit, $offset);
}
$batch = $this->getUsersForUID($batch);

Expand Down

0 comments on commit 2622dda

Please sign in to comment.