summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--settings/ajax/grouplist.php4
1 files changed, 1 insertions, 3 deletions
diff --git a/settings/ajax/grouplist.php b/settings/ajax/grouplist.php
index 52df98c4e5e..93bb510773d 100644
--- a/settings/ajax/grouplist.php
+++ b/settings/ajax/grouplist.php
@@ -38,9 +38,7 @@ $adminGroups = array();
$groupManager = \OC_Group::getManager();
$isAdmin = OC_User::isAdminUser(OC_User::getUser());
-//we pass isAdmin as true, because OC_SubAdmin has no search feature,
-//groups will be filtered out later
-$groupsInfo = new \OC\Group\MetaData(OC_User::getUser(), true, $groupManager);
+$groupsInfo = new \OC\Group\MetaData(OC_User::getUser(), $isAdmin, $groupManager);
$groupsInfo->setSorting($groupsInfo::SORT_USERCOUNT);
list($adminGroups, $groups) = $groupsInfo->get($groupPattern, $pattern);