Fix: Check all circle shares for permissions instead of returning after the first

This commit is contained in:
Bink
2022-03-09 08:54:52 +01:00
committed by backportbot[bot]
parent 1cdea9dba0
commit b6cce55325

View File

@@ -213,7 +213,9 @@ class PermissionService {
if ($this->circlesService->isCirclesEnabled() && $acl->getType() === Acl::PERMISSION_TYPE_CIRCLE) {
try {
return $this->circlesService->isUserInCircle($acl->getParticipant(), $userId) && $acl->getPermission($permission);
if ($this->circlesService->isUserInCircle($acl->getParticipant(), $userId) && $acl->getPermission($permission)) {
return true;
}
} catch (\Exception $e) {
$this->logger->info('Member not found in circle that was accessed. This should not happen.');
}