summaryrefslogtreecommitdiffstats
path: root/apps/user_ldap/lib
diff options
context:
space:
mode:
Diffstat (limited to 'apps/user_ldap/lib')
-rw-r--r--apps/user_ldap/lib/Access.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/apps/user_ldap/lib/Access.php b/apps/user_ldap/lib/Access.php
index 3d182077764..e255156dcf6 100644
--- a/apps/user_ldap/lib/Access.php
+++ b/apps/user_ldap/lib/Access.php
@@ -564,7 +564,11 @@ class Access extends LDAPUtility implements IUserTools {
}
if(is_null($ldapName)) {
- $ldapName = $this->readAttribute($fdn, $nameAttribute);
+ if ($isUser) {
+ $ldapName = $this->readAttribute($fdn, $nameAttribute, $this->connection->ldapUserFilter);
+ } else {
+ $ldapName = $this->readAttribute($fdn, $nameAttribute);
+ }
if(!isset($ldapName[0]) && empty($ldapName[0])) {
\OCP\Util::writeLog('user_ldap', 'No or empty name for '.$fdn.'.', \OCP\Util::INFO);
return false;