adjust to nested group fix
This commit is contained in:
parent
9d03b7c6b7
commit
845485cfe6
1 changed files with 6 additions and 1 deletions
|
@ -31,6 +31,7 @@ namespace OCA\user_ldap;
|
|||
|
||||
use OCA\user_ldap\lib\Access;
|
||||
use OCA\user_ldap\lib\BackendUtility;
|
||||
use OCA\user_ldap\lib\user\User;
|
||||
|
||||
class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface {
|
||||
protected $enabled = false;
|
||||
|
@ -195,7 +196,11 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface {
|
|||
return array();
|
||||
}
|
||||
$seen[$DN] = 1;
|
||||
$groups = $this->access->readAttribute($DN, 'memberOf');
|
||||
$user = $this->access->userManager->get($DN);
|
||||
if(!$user instanceof User) {
|
||||
return array();
|
||||
}
|
||||
$groups = $user->getMemberOfGroups();
|
||||
if (!is_array($groups)) {
|
||||
return array();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue