user Group->users as assosiative array
This commit is contained in:
parent
b126374780
commit
3d29992378
1 changed files with 3 additions and 5 deletions
|
@ -90,14 +90,12 @@ class Group {
|
|||
* @return bool
|
||||
*/
|
||||
public function inGroup($user) {
|
||||
foreach ($this->users as $cachedUser) {
|
||||
if ($user->getUID() === $cachedUser->getUID()) {
|
||||
return true;
|
||||
}
|
||||
if (isset($this->users[$user->getUID()])) {
|
||||
return true;
|
||||
}
|
||||
foreach ($this->backends as $backend) {
|
||||
if ($backend->inGroup($user->getUID(), $this->gid)) {
|
||||
$this->users[] = $user;
|
||||
$this->users[$user->getUID()] = $user;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue