diff options
author | Lukas Reschke <lukas@statuscode.ch> | 2012-10-16 00:43:19 +0200 |
---|---|---|
committer | Lukas Reschke <lukas@statuscode.ch> | 2012-10-16 00:47:38 +0200 |
commit | c404148f9a1c33c1b8966653f4bc37fe2a44a285 (patch) | |
tree | 10a4b3971d88de041e5b4f8a48f94910f3489f20 /settings | |
parent | 91d4b23efe6446240d89425060ca4483a1eecf77 (diff) | |
download | nextcloud-server-c404148f9a1c33c1b8966653f4bc37fe2a44a285.tar.gz nextcloud-server-c404148f9a1c33c1b8966653f4bc37fe2a44a285.zip |
Password check for admins
Diffstat (limited to 'settings')
-rw-r--r-- | settings/ajax/changepassword.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/settings/ajax/changepassword.php b/settings/ajax/changepassword.php index b797fcf9185..822a95c1bc2 100644 --- a/settings/ajax/changepassword.php +++ b/settings/ajax/changepassword.php @@ -19,10 +19,14 @@ if(OC_SubAdmin::isUserAccessible(OC_User::getUser(), $username)) { $userstatus = 'subadmin'; } if(OC_User::getUser() === $username) { - if (OC_User::checkPassword($username, $oldPassword) && ($userstatus === null || !OC_JSON::isUserVerified())) + if (OC_User::checkPassword($username, $oldPassword)) { $userstatus = 'user'; - } + } else { + if (!OC_JSON::isUserVerified()) { + $userstatus = null; + } + } } if(is_null($userstatus)) { |