From: Lukas Reschke Date: Sat, 7 Jul 2012 13:00:02 +0000 (+0200) Subject: Fixes a problem with the user creation ("User already existed" even if the user don... X-Git-Tag: v4.5.0beta1~74^2~225^2~20 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=ec7bb86b2875c9e5afbd7db57de3c872afc3e90b;p=nextcloud-server.git Fixes a problem with the user creation ("User already existed" even if the user don't exists.) Thanks to Phil Reinhardt for pointing this out. --- diff --git a/lib/user.php b/lib/user.php index d02c1208a8d..3029ec1acc1 100644 --- a/lib/user.php +++ b/lib/user.php @@ -345,9 +345,8 @@ class OC_User { * @return boolean */ public static function userExists($uid){ - static $user_exists_checked = null; - if (!is_null($user_exists_checked)) { - return $user_exists_checked; + if (!is_null($user_exists_checked)) { + return $user_exists_checked; } foreach(self::$_usedBackends as $backend){ $result=$backend->userExists($uid);