[Changed] clear code and adjust Naming

This commit is contained in:
MaxBUhe 2024-05-31 15:47:54 +02:00
parent e500814e7e
commit 9a5e1506e8
2 changed files with 6 additions and 11 deletions

View File

@ -6,11 +6,8 @@ use D3\GoogleAnalytics4\Application\Model\CMP\Usercentrics;
class ManagerTypes class ManagerTypes
{ {
#ToDo: make own classes for each of the manager const EXTERNAL_SERVICE = "eigener Service";
const NET_COOKIE_MANAGER = "Netensio Cookie Manager";
const EXTERNAL_SERVICE = "externalService";
const NET_COOKIE_MANAGER = "net_cookie_manager";
/** /**
* Further information's: * Further information's:
@ -20,11 +17,9 @@ class ManagerTypes
const CONSENTMANAGER = "Consentmanager"; const CONSENTMANAGER = "Consentmanager";
const CONSENTMANAGER = "CONSENTMANAGER"; const COOKIEFIRST = "Cookiefirst";
const COOKIEFIRST = "COOKIEFIRST"; const COOKIEBOT = "Cookiebot";
const COOKIEBOT = "COOKIEBOT";
/** /**
* @return array * @return array
@ -49,6 +44,6 @@ class ManagerTypes
*/ */
public function isManagerInList(string $sManager) :bool public function isManagerInList(string $sManager) :bool
{ {
return in_array($sManager, $this->getManagerList(), true); return in_array($sManager, array_keys($this->getManagerList()), true);
} }
} }

View File

@ -79,7 +79,7 @@ class ViewConfig extends ViewConfig_parent
} }
// No Cookie Manager in use // No Cookie Manager in use
if (!$this->shallUseOwnCookieManager()) { if (false === $this->shallUseOwnCookieManager()) {
return true; return true;
} }