diff --git a/Classes/Controller/JavaScriptController.php b/Classes/Controller/JavaScriptController.php index c2022d5..e189b7a 100644 --- a/Classes/Controller/JavaScriptController.php +++ b/Classes/Controller/JavaScriptController.php @@ -88,7 +88,7 @@ function ($key) { $decisionTtl = $cookieSettings->getProperty('decisionTtl') ?? 0; $expireDate = clone $consentDate; $expireDate->add(\DateInterval::createFromDateString($decisionTtl . ' seconds')); - if ($expireDate < new \DateTime('now')) { + if ($decisionTtl > 0 && $expireDate < new \DateTime('now')) { $this->response->setContentType('text/javascript'); $this->response->setContent(''); return;