Issue Bug Closed

#97699Argument must be array when accessing a custom finisher variable

Josua Vogel 05/27/22, 13:55 updated 10/04/22, 14:04

Description

If you try to access a finisher variable, of a finisher which wasn’t executed before, by using

$this->finisherContext->getFinisherVariableProvider()->get('NotExecutedFinisher', 'key', 'default')

the following error is thrown:
Argument #1 ($array) must be of type array, null given

This error happens on PHP 8 and higher, because TYPO3\CMS\Core\Utility\ArrayUtility::getValueByPath() expects an array as first parameter, but receives null.

Reviews 3