summaryrefslogtreecommitdiffstats
path: root/settings/ajax/removeuser.php
diff options
context:
space:
mode:
Diffstat (limited to 'settings/ajax/removeuser.php')
-rw-r--r--settings/ajax/removeuser.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/settings/ajax/removeuser.php b/settings/ajax/removeuser.php
index 9ffb32a0b23..bf3a34f1472 100644
--- a/settings/ajax/removeuser.php
+++ b/settings/ajax/removeuser.php
@@ -10,7 +10,7 @@ if(OC_User::getUser() === $username) {
exit;
}
-if(!OC_Group::inGroup(OC_User::getUser(), 'admin') && !OC_SubAdmin::isUserAccessible(OC_User::getUser(), $username)) {
+if(!OC_User::isAdminUser(OC_User::getUser()) && !OC_SubAdmin::isUserAccessible(OC_User::getUser(), $username)) {
$l = OC_L10N::get('core');
OC_JSON::error(array( 'data' => array( 'message' => $l->t('Authentication error') )));
exit();