From ccd57ce1b1e851b90f3481538352a9b29a9fcc2a Mon Sep 17 00:00:00 2001 From: "John Molakvoæ (skjnldsv)" Date: Sat, 17 Mar 2018 12:18:22 +0100 Subject: Allow empty emails provisionning api MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: John Molakvoæ (skjnldsv) --- apps/provisioning_api/lib/Controller/UsersController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'apps') diff --git a/apps/provisioning_api/lib/Controller/UsersController.php b/apps/provisioning_api/lib/Controller/UsersController.php index 087e65a1bca..2c89efc8233 100644 --- a/apps/provisioning_api/lib/Controller/UsersController.php +++ b/apps/provisioning_api/lib/Controller/UsersController.php @@ -451,7 +451,7 @@ class UsersController extends OCSController { $this->config->setUserValue($targetUser->getUID(), 'core', 'lang', $value); break; case AccountManager::PROPERTY_EMAIL: - if(filter_var($value, FILTER_VALIDATE_EMAIL)) { + if(filter_var($value, FILTER_VALIDATE_EMAIL) || $value === '') { $targetUser->setEMailAddress($value); } else { throw new OCSException('', 102); -- cgit v1.2.3