From 89421b4e62a7267b0da56046111abdc6436570d4 Mon Sep 17 00:00:00 2001 From: amoser Date: Wed, 10 Nov 2021 12:48:11 +0100 Subject: [PATCH] getProfilingConsent() and getCustomerLanguage() -> return same type as pimcore-models or else there is a fatal error --- src/Model/Traits/CustomerTrait.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Model/Traits/CustomerTrait.php b/src/Model/Traits/CustomerTrait.php index c5cacf28..90e27e23 100644 --- a/src/Model/Traits/CustomerTrait.php +++ b/src/Model/Traits/CustomerTrait.php @@ -61,13 +61,13 @@ public function getRelatedCustomerGroups() return []; } - public function getProfilingConsent() + public function getProfilingConsent(): ?\Pimcore\Model\DataObject\Data\Consent { if (is_callable('parent::getProfilingConsent')) { return parent::getProfilingConsent(); } - return true; + return null; } /** @@ -117,7 +117,7 @@ public function needsExportByNewsletterProviderHandler(NewsletterProviderHandler return $this->getPublished() && $this->getActive(); } - public function getCustomerLanguage() + public function getCustomerLanguage(): ?string { return null; }