From e1e3649847cd0bbd9b43322d26c7b5cf7ba09bac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tomasz=20Wolda=C5=84ski?= <t.woldanski@macopedia.com> Date: Tue, 16 Aug 2022 10:41:45 +0200 Subject: [PATCH] [BUGFIX] Fix warning on array key "data" Patch fixes warning on PHP 8.1 in MenuProcessor Resolves: #98150 Releases: main, 11.5 Change-Id: I9cee1d6d0adcde22a74e040ac53657db3348c514 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/75475 Reviewed-by: Oliver Klee <typo3-coding@oliverklee.de> Reviewed-by: Benni Mack <benni@typo3.org> Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch> Tested-by: core-ci <typo3@b13.com> Tested-by: Benni Mack <benni@typo3.org> Tested-by: Christian Kuhn <lolli@schwarzbu.ch> --- .../frontend/Classes/DataProcessing/MenuProcessor.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/typo3/sysext/frontend/Classes/DataProcessing/MenuProcessor.php b/typo3/sysext/frontend/Classes/DataProcessing/MenuProcessor.php index 52147a1b2d55..8f6780d6a7cf 100644 --- a/typo3/sysext/frontend/Classes/DataProcessing/MenuProcessor.php +++ b/typo3/sysext/frontend/Classes/DataProcessing/MenuProcessor.php @@ -485,9 +485,9 @@ class MenuProcessor implements DataProcessorInterface } $request = $this->cObj->getRequest(); $recordContentObjectRenderer = GeneralUtility::makeInstance(ContentObjectRenderer::class); - $recordContentObjectRenderer->start($page['data'], 'pages', $request); - $processedPage = $this->contentDataProcessor->process($recordContentObjectRenderer, $processorConfiguration, $page); - return $processedPage; + $recordContentObjectRenderer->start($page['data'] ?? [], 'pages', $request); + + return $this->contentDataProcessor->process($recordContentObjectRenderer, $processorConfiguration, $page); } /** -- GitLab