Issue Bug Closed

#103873PHP Warning: Undefined Array Key "avatar" when saving profile of a non-admin user with disabled avatar field

Ziad Abdul Hai 05/22/24, 04:49 updated 07/09/24, 15:35

Description

Issue:

Saving the profile of a non-admin user with disabled avatar field leads to warnings in PHP 8+ on TYPO3 12 and TYPO3 13.1

Steps to reproduce the issue:

  • create an empty TYPO3 System (PHP Version 8.2)
  • create a rootpage
  • create an editor user group and user
  • disable the avatar field of this user with User-TSconfig (setup.fields.avatar.disabled=1)
  • switch to this user
  • edit the profile and save it or just save it, which causes the PHP warning:
 PHP Warning: Undefined array key "avatar" in /var/www/html/typo3/sysext/setup/Classes/Controller/SetupModuleController.php line 299 (main)
 PHP Warning: Undefined array key "avatar" in /var/www/html/typo3/sysext/setup/Classes/Controller/SetupModuleController.php line 301 (12.4)

Reviews 2