diff options
author | Christopher Ng <chrng8@gmail.com> | 2021-10-14 08:19:40 +0000 |
---|---|---|
committer | Christopher Ng <chrng8@gmail.com> | 2021-10-19 04:59:35 +0000 |
commit | 309354852f12ae88d5eef05d311d6ebcba8ee762 (patch) | |
tree | 640c4e2394ba2a868d8d1cb6b5271fd1271bbdab /apps/provisioning_api | |
parent | 7215148a242815a5064ce5d00a387c634dc936f3 (diff) | |
download | nextcloud-server-309354852f12ae88d5eef05d311d6ebcba8ee762.tar.gz nextcloud-server-309354852f12ae88d5eef05d311d6ebcba8ee762.zip |
Profile backend
Signed-off-by: Christopher Ng <chrng8@gmail.com>
Diffstat (limited to 'apps/provisioning_api')
-rw-r--r-- | apps/provisioning_api/lib/Controller/UsersController.php | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/apps/provisioning_api/lib/Controller/UsersController.php b/apps/provisioning_api/lib/Controller/UsersController.php index 714759ccc0f..38d51857ffc 100644 --- a/apps/provisioning_api/lib/Controller/UsersController.php +++ b/apps/provisioning_api/lib/Controller/UsersController.php @@ -721,11 +721,11 @@ class UsersController extends AUserData { * * @param string $userId * @param string $key - * @param string|bool $value + * @param string $value * @return DataResponse * @throws OCSException */ - public function editUser(string $userId, string $key, $value): DataResponse { + public function editUser(string $userId, string $key, string $value): DataResponse { $currentLoggedInUser = $this->userSession->getUser(); $targetUser = $this->userManager->get($userId); @@ -961,11 +961,6 @@ class UsersController extends AUserData { $this->accountManager->updateAccount($userAccount); break; case IAccountManager::PROPERTY_PROFILE_ENABLED: - if (!is_bool($value)) { - throw new OCSException('Invalid value, value must be a boolean', 102); - } - $value = $value === true ? '1' : '0'; - $userAccount = $this->accountManager->getAccount($targetUser); try { $userProperty = $userAccount->getProperty($key); |