diff options
Diffstat (limited to 'lib/private/User/Manager.php')
-rw-r--r-- | lib/private/User/Manager.php | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/private/User/Manager.php b/lib/private/User/Manager.php index b1f328b6f1b..3d016700ee3 100644 --- a/lib/private/User/Manager.php +++ b/lib/private/User/Manager.php @@ -281,11 +281,9 @@ class Manager extends PublicEmitter implements IUserManager { if (strlen(trim($uid, "\t\n\r\0\x0B\xe2\x80\x8b")) !== strlen(trim($uid))) { throw new \Exception($l->t('Username contains whitespace at the beginning or at the end')); } - // if password link is sent use random password; permit empty password - if (trim($password) == '' && $this->config->getAppValue('core', 'umgmt_send_passwordlink', 'false') === 'false') { + // No empty password + if (trim($password) == '') { throw new \Exception($l->t('A valid password must be provided')); - } else { - $password = \OC::$server->getSecureRandom()->generate(32); } // Check if user already exists |