diff options
author | Robin Appelman <robin@icewind.nl> | 2017-07-13 14:33:46 +0200 |
---|---|---|
committer | Robin Appelman <robin@icewind.nl> | 2017-07-13 15:53:14 +0200 |
commit | 5185a3c0c957bc01f159118a32a0a4aaf1f23532 (patch) | |
tree | 9d268243138c7739bec627721c4b8eac8a9aaef6 /lib/private | |
parent | f71457782b1c0e6aa66ba6b2aac126aa5a2bc9dc (diff) | |
download | nextcloud-server-5185a3c0c957bc01f159118a32a0a4aaf1f23532.tar.gz nextcloud-server-5185a3c0c957bc01f159118a32a0a4aaf1f23532.zip |
null users dont exist
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'lib/private')
-rw-r--r-- | lib/private/User/Manager.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/private/User/Manager.php b/lib/private/User/Manager.php index c04f426c2cf..ded807a223b 100644 --- a/lib/private/User/Manager.php +++ b/lib/private/User/Manager.php @@ -126,6 +126,9 @@ class Manager extends PublicEmitter implements IUserManager { * @return \OC\User\User|null Either the user or null if the specified user does not exist */ public function get($uid) { + if (is_null($uid) || $uid === '' || $uid === false) { + return null; + } if (isset($this->cachedUsers[$uid])) { //check the cache first to prevent having to loop over the backends return $this->cachedUsers[$uid]; } |