diff options
author | Arthur Schiwon <blizzz@owncloud.com> | 2015-10-28 17:34:23 +0100 |
---|---|---|
committer | Arthur Schiwon <blizzz@owncloud.com> | 2015-11-06 15:21:56 +0100 |
commit | 133e3fe89d294244287d7cfa3deda79ab20143c3 (patch) | |
tree | 2d1b7cd11409c6db091f158e2986e3fd641b851a /apps/user_ldap/group_ldap.php | |
parent | 82f8374f63967d3f3d0000b9819a794f0183f889 (diff) | |
download | nextcloud-server-133e3fe89d294244287d7cfa3deda79ab20143c3.tar.gz nextcloud-server-133e3fe89d294244287d7cfa3deda79ab20143c3.zip |
remove uselessly used parameter, read all user attributes also when looking up users in groups
Diffstat (limited to 'apps/user_ldap/group_ldap.php')
-rw-r--r-- | apps/user_ldap/group_ldap.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/user_ldap/group_ldap.php b/apps/user_ldap/group_ldap.php index d7ca786a439..7c06e24293e 100644 --- a/apps/user_ldap/group_ldap.php +++ b/apps/user_ldap/group_ldap.php @@ -553,6 +553,7 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface { $groupUsers = array(); $isMemberUid = (strtolower($this->access->connection->ldapGroupMemberAssocAttr) === 'memberuid'); + $attrs = $this->access->userManager->getAttributes(true); foreach($members as $member) { if($isMemberUid) { //we got uids, need to get their DNs to 'translate' them to user names @@ -560,11 +561,11 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface { str_replace('%uid', $member, $this->access->connection->ldapLoginFilter), $this->access->getFilterPartForUserSearch($search) )); - $ldap_users = $this->access->fetchListOfUsers($filter, 'dn'); + $ldap_users = $this->access->fetchListOfUsers($filter, $attrs, 1); if(count($ldap_users) < 1) { continue; } - $groupUsers[] = $this->access->dn2username($ldap_users[0]); + $groupUsers[] = $this->access->dn2username($ldap_users[0]['dn'][0]); } else { //we got DNs, check if we need to filter by search or we can give back all of them if(!empty($search)) { |