mirror of
https://github.com/nextcloud/server.git
synced 2026-06-10 09:13:19 -04:00
Use UID instead of login name
Login name can be something different and thus I'm pretty sure this will break in combination with external auth providers such as LDAP.
This commit is contained in:
parent
5aad902507
commit
d712c27fe1
1 changed files with 1 additions and 1 deletions
|
|
@ -25,7 +25,7 @@ OC_JSON::checkSubAdminUser();
|
|||
|
||||
$userCount = 0;
|
||||
|
||||
$currentUser = \OC::$server->getUserSession()->getLoginName();
|
||||
$currentUser = \OC::$server->getUserSession()->getUser()->getUID();
|
||||
|
||||
if (!OC_User::isAdminUser($currentUser)) {
|
||||
$groups = OC_SubAdmin::getSubAdminsGroups($currentUser);
|
||||
|
|
|
|||
Loading…
Reference in a new issue