diff --git a/Classes/Cache/PagesCacheService.php b/Classes/Cache/PagesCacheService.php index 1b092123..09d9c20c 100644 --- a/Classes/Cache/PagesCacheService.php +++ b/Classes/Cache/PagesCacheService.php @@ -44,7 +44,7 @@ public function storeMarkupInCache(string $markup): void $this->cache->set( $this->getCacheIdentifier(), $markup, - \array_merge(['pageId_' . $this->controller->page['uid']], $this->controller->getPageCacheTags()), + \array_merge(['pageId_' . ($this->controller->page['uid'] ?? 0)], $this->controller->getPageCacheTags()), 86400, ); } diff --git a/phpstan.baseline.neon b/phpstan.baseline.neon index 1e7d9a5b..c05e5521 100644 --- a/phpstan.baseline.neon +++ b/phpstan.baseline.neon @@ -5,11 +5,6 @@ parameters: count: 1 path: Classes/Cache/PagesCacheService.php - - - message: "#^Offset 'uid' does not exist on array\\|null\\.$#" - count: 1 - path: Classes/Cache/PagesCacheService.php - - message: "#^Instanceof between mixed and Brotkrueml\\\\Schema\\\\Core\\\\Model\\\\TypeInterface will always evaluate to false\\.$#" count: 1