LDAP: check whether user exists for before trying to determine displayname
This commit is contained in:
parent
18fccf6612
commit
50d0f48ee4
|
@ -217,6 +217,10 @@ class USER_LDAP extends lib\Access implements \OCP\UserInterface {
|
|||
* @return display name
|
||||
*/
|
||||
public function getDisplayName($uid) {
|
||||
if(!$this->userExists($uid)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$cacheKey = 'getDisplayName'.$uid;
|
||||
if(!is_null($displayName = $this->connection->getFromCache($cacheKey))) {
|
||||
return $displayName;
|
||||
|
|
Loading…
Reference in New Issue