fix more review comments for #18042 / #17759

This commit is contained in:
Frédéric Fortier 2015-08-07 08:56:28 -04:00
parent e0469d0013
commit a55f233e9f
1 changed files with 3 additions and 4 deletions

View File

@ -201,9 +201,9 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface {
}
$groups = $this->access->groupsMatchFilter($groups);
$allGroups = $groups;
foreach ($groups as $group) {
$nestedGroups = $this->access->connection->ldapNestedGroups;
if (!empty($nestedGroups)) {
$nestedGroups = $this->access->connection->ldapNestedGroups;
if (intval($nestedGroups) === 1) {
foreach ($groups as $group) {
$subGroups = $this->_getGroupDNsFromMemberOf($group, $seen);
$allGroups = array_merge($allGroups, $subGroups);
}
@ -408,7 +408,6 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface {
&& intval($this->access->connection->useMemberOfToDetectMembership) === 1
) {
$groupDNs = $this->_getGroupDNsFromMemberOf($userDN);
if (is_array($groupDNs)) {
foreach ($groupDNs as $dn) {
$groups[] = $this->access->dn2groupname($dn);