mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-08-09 10:22:51 +03:00
Started more formal permission test case definitions
This commit is contained in:
@@ -107,7 +107,7 @@ class PermissionApplicator
|
||||
$allowedByTypeById = ['fallback' => [], 'user' => [], 'role' => []];
|
||||
/** @var EntityPermission $permission */
|
||||
foreach ($relevantPermissions as $permission) {
|
||||
$allowedByTypeById[$permission->getAssignedType()][$permission->getAssignedTypeId()] = $permission->$permission;
|
||||
$allowedByTypeById[$permission->getAssignedType()][$permission->getAssignedTypeId()] = boolval($permission->$action);
|
||||
}
|
||||
|
||||
$inheriting = !isset($allowedByTypeById['fallback'][0]);
|
||||
|
Reference in New Issue
Block a user