#105834$GLOBALS['BE_USER'] null in upgrade wizard
Description
Steps to reproduce:
Add a custom upgrade wizard with Datahandler and run.
$dataHandler = GeneralUtility::makeInstance(DataHandler::class);
$dataHandler->start($data, []);
Expected result:
Wizard runs and executes its functions.
Result:
Error: Call to a member function getTSConfig() on null in vendor/typo3/cms-core/Classes/DataHandling/DataHandler.php line 647
Lines 636-647
// Initializing BE_USER
$this->BE_USER = is_object($altUserObject) ? $altUserObject : $GLOBALS['BE_USER'];
$this->userid = (int)($this->BE_USER->user['uid'] ?? 0);
$this->admin = $this->BE_USER->user['admin'] ?? false;
// set correlation id for each new set of data or commands
$this->correlationId = CorrelationId::forScope(
md5(StringUtility::getUniqueId(self::class))
);
// Get default values from user TSconfig
$tcaDefaultOverride = $this->BE_USER->getTSConfig()['TCAdefaults.'] ?? null;
The initialization in line 637 results to null as $GLOBALS[‘BE_USER’] is null at this point.
PHP 8.2
TYPO3 12.4.20 – 12.4.24 confirmed
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.