From 9a5e1506e875e8a4c9500bd7254d27de999d41ca Mon Sep 17 00:00:00 2001 From: MaxBUhe Date: Fri, 31 May 2024 15:47:54 +0200 Subject: [PATCH] [Changed] clear code and adjust Naming --- Application/Model/ManagerTypes.php | 15 +++++---------- Modules/Core/ViewConfig.php | 2 +- 2 files changed, 6 insertions(+), 11 deletions(-) diff --git a/Application/Model/ManagerTypes.php b/Application/Model/ManagerTypes.php index 191c9c5..5db77ff 100644 --- a/Application/Model/ManagerTypes.php +++ b/Application/Model/ManagerTypes.php @@ -6,11 +6,8 @@ use D3\GoogleAnalytics4\Application\Model\CMP\Usercentrics; class ManagerTypes { - #ToDo: make own classes for each of the manager - - - const EXTERNAL_SERVICE = "externalService"; - const NET_COOKIE_MANAGER = "net_cookie_manager"; + const EXTERNAL_SERVICE = "eigener Service"; + const NET_COOKIE_MANAGER = "Netensio Cookie Manager"; /** * Further information's: @@ -20,11 +17,9 @@ class ManagerTypes const CONSENTMANAGER = "Consentmanager"; - const CONSENTMANAGER = "CONSENTMANAGER"; + const COOKIEFIRST = "Cookiefirst"; - const COOKIEFIRST = "COOKIEFIRST"; - - const COOKIEBOT = "COOKIEBOT"; + const COOKIEBOT = "Cookiebot"; /** * @return array @@ -49,6 +44,6 @@ class ManagerTypes */ public function isManagerInList(string $sManager) :bool { - return in_array($sManager, $this->getManagerList(), true); + return in_array($sManager, array_keys($this->getManagerList()), true); } } \ No newline at end of file diff --git a/Modules/Core/ViewConfig.php b/Modules/Core/ViewConfig.php index 3ff33db..152b0f2 100644 --- a/Modules/Core/ViewConfig.php +++ b/Modules/Core/ViewConfig.php @@ -79,7 +79,7 @@ class ViewConfig extends ViewConfig_parent } // No Cookie Manager in use - if (!$this->shallUseOwnCookieManager()) { + if (false === $this->shallUseOwnCookieManager()) { return true; }