diff --git a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php index e3d7a8246699..6147b4ec8f6b 100644 --- a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php +++ b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php @@ -687,6 +687,9 @@ public function setCurrentVal($value) */ public function cObjGet($setup, $addKey = '') { + if (!is_array($setup)) { + return ''; + } return implode('', $this->cObjGetSeparated($setup, $addKey)); } @@ -698,7 +701,7 @@ public function cObjGet($setup, $addKey = '') */ public function cObjGetSeparated(?array $setup, string $addKey = ''): array { - if (!is_array($setup) || $setup === []) { + if ($setup === null || $setup === []) { return []; } $sKeyArray = ArrayUtility::filterAndSortByNumericKeys($setup);