mirror of
https://github.com/netzbegruenung/user_saml.git
synced 2024-05-02 17:14:53 +02:00
Use builtin user group ids getter
Signed-off-by: Jonathan Treffler <mail@jonathan-treffler.de> Signed-off-by: Giuliano Mele <giuliano.mele@verdigado.com>
This commit is contained in:
parent
68f76b66c7
commit
e90aca0a23
|
@ -66,10 +66,7 @@ class GroupManager
|
|||
return;
|
||||
}
|
||||
$this->translateGroupToIds($samlGroups);
|
||||
$assigned = $this->groupManager->getUserGroups($user);
|
||||
$assigned = array_map(function(IGroup $group){
|
||||
return $group->getGID();
|
||||
}, $assigned);
|
||||
$assigned = $this->groupManager->getUserGroupIds($user);
|
||||
$this->removeGroups($user, array_diff($assigned, $samlGroups));
|
||||
$this->addGroups($user, array_diff($samlGroups, $assigned));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue