From 0ff4381305457dcb01fcd735a1766f391c5d8ede Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Fri, 29 Nov 2019 11:39:49 -0500 Subject: [PATCH] Ensure the existence of expected default permission keys in ACL::getFullSelectorHTML - Addresses https://sozialwolke.net/display/703b8751-145d-e11f-a923-98e999239905 --- src/Core/ACL.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Core/ACL.php b/src/Core/ACL.php index 880a1e47ff..0eb2ecc8b3 100644 --- a/src/Core/ACL.php +++ b/src/Core/ACL.php @@ -333,6 +333,13 @@ class ACL extends BaseObject // Defaults user permissions if (empty($default_permissions)) { $default_permissions = self::getDefaultUserPermissions($user); + } else { + $default_permissions = [ + 'allow_cid' => $default_permissions['allow_cid'] ?? [], + 'allow_gid' => $default_permissions['allow_gid'] ?? [], + 'deny_cid' => $default_permissions['deny_cid'] ?? [], + 'deny_gid' => $default_permissions['deny_gid'] ?? [], + ]; } if (count($default_permissions['allow_cid']) -- 2.39.5