Scrutinizer Auto-Fixes

This commit consists of patches automatically generated for this project on https://scrutinizer-ci.com
This commit is contained in:
Scrutinizer Auto-Fixer
2018-05-12 11:10:23 +00:00
parent 08d9d51bea
commit b633d82c5e
17 changed files with 77 additions and 71 deletions

View File

@@ -185,8 +185,8 @@ class PermissionService {
*/
public function findUsers($boardId) {
// cache users of a board so we don't query them for every cards
if (array_key_exists((string)$boardId, $this->users)) {
return $this->users[(string)$boardId];
if (array_key_exists((string) $boardId, $this->users)) {
return $this->users[(string) $boardId];
}
try {
$board = $this->boardMapper->find($boardId);
@@ -203,14 +203,14 @@ class PermissionService {
$user = $this->userManager->get($acl->getParticipant());
$users[$user->getUID()] = new User($user);
}
if($acl->getType() === Acl::PERMISSION_TYPE_GROUP) {
if ($acl->getType() === Acl::PERMISSION_TYPE_GROUP) {
$group = $this->groupManager->get($acl->getParticipant());
foreach ($group->getUsers() as $user) {
$users[$user->getUID()] = new User($user);
}
}
}
$this->users[(string)$boardId] = $users;
return $this->users[(string)$boardId];
$this->users[(string) $boardId] = $users;
return $this->users[(string) $boardId];
}
}