diff options
author | Morris Jobke <hey@morrisjobke.de> | 2018-04-11 16:21:32 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-11 16:21:32 +0200 |
commit | e6c146121e708bd7aee099ecfe67daae4a54ea20 (patch) | |
tree | 5b7f91deb070353b581790df99db47ea5bc49ffa /apps/provisioning_api | |
parent | fed9140abdecdfbfc3c5f6a7c24779dac66ac0e9 (diff) | |
parent | 89da1af889f73b67bb3aedb5ffb2ee6cbd2be062 (diff) | |
download | nextcloud-server-e6c146121e708bd7aee099ecfe67daae4a54ea20.tar.gz nextcloud-server-e6c146121e708bd7aee099ecfe67daae4a54ea20.zip |
Merge pull request #9144 from nextcloud/allow-lang-ocs-api
Add language support for user creation in api
Diffstat (limited to 'apps/provisioning_api')
-rw-r--r-- | apps/provisioning_api/lib/Controller/UsersController.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/apps/provisioning_api/lib/Controller/UsersController.php b/apps/provisioning_api/lib/Controller/UsersController.php index 420c09dfecb..7bbbe554838 100644 --- a/apps/provisioning_api/lib/Controller/UsersController.php +++ b/apps/provisioning_api/lib/Controller/UsersController.php @@ -206,7 +206,8 @@ class UsersController extends AUserData { string $email = '', array $groups = [], array $subadmin = [], - string $quota = ''): DataResponse { + string $quota = '', + string $language = 'en'): DataResponse { $user = $this->userSession->getUser(); $isAdmin = $this->groupManager->isAdmin($user->getUID()); $subAdminManager = $this->groupManager->getSubAdmin(); @@ -279,6 +280,10 @@ class UsersController extends AUserData { $this->editUser($userid, 'quota', $quota); } + if ($language !== '') { + $this->editUser($userid, 'language', $language); + } + // Send new user mail only if a mail is set if ($email !== '') { $newUser->setEMailAddress($email); |