From 8ac4b05ebfa51dac2e28518dbc924348e96cd941 Mon Sep 17 00:00:00 2001 From: Marcin Haba Date: Thu, 15 Jun 2023 10:43:17 +0200 Subject: [PATCH] baculum: Fix storing ACL config actions for very old PHP versions --- gui/baculum/protected/API/Modules/BaculaConfigACL.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gui/baculum/protected/API/Modules/BaculaConfigACL.php b/gui/baculum/protected/API/Modules/BaculaConfigACL.php index f5144b327..9180ed41e 100644 --- a/gui/baculum/protected/API/Modules/BaculaConfigACL.php +++ b/gui/baculum/protected/API/Modules/BaculaConfigACL.php @@ -34,7 +34,7 @@ class BaculaConfigACL extends APIModule /** * Special config ACL action names. */ - const CONFIG_ACL_ACTIONS = [ + private static $config_acl_actions = [ 'READ', 'CREATE', 'UPDATE', @@ -44,7 +44,7 @@ class BaculaConfigACL extends APIModule * Validate if request command is allowed. * * @param string $console_name Director Console name - * @param string $action current action (@see BaculaConfigACL::CONFIG_ACL_ACTIONS) + * @param string $action current action (@see BaculaConfigACL::$config_acl_actions) * @param string $component_type component type (currently not used) * @param string $resource_type resource type * @return bool true if request command is allowed, false otherwise @@ -73,7 +73,7 @@ class BaculaConfigACL extends APIModule */ private function validateAction($action) { - return in_array($action, self::CONFIG_ACL_ACTIONS); + return in_array($action, self::$config_acl_actions); } /** -- 2.47.3