[BUGFIX] New content element wizard fails for not given header value 99/55299/2
authorSteffen Kamper <info@sk-typo3.de>
Sat, 6 Jan 2018 11:40:15 +0000 (12:40 +0100)
committerTymoteusz Motylewski <t.motylewski@gmail.com>
Tue, 9 Jan 2018 20:52:16 +0000 (21:52 +0100)
As additional sanitation, accept an empty header for items groups
by rendering "-" if none is given.

Resolves: #83484
Releases: master, 8.7
Change-Id: Iff733cdcbdba18a52a5430b661fafd9692483659
Reviewed-on: https://review.typo3.org/55299
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Andreas Fernandez <a.fernandez@scripting-base.de>
Tested-by: Andreas Fernandez <a.fernandez@scripting-base.de>
Reviewed-by: Tymoteusz Motylewski <t.motylewski@gmail.com>
Tested-by: Tymoteusz Motylewski <t.motylewski@gmail.com>
typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php

index a0604de..40c3f3b 100644 (file)
@@ -254,9 +254,9 @@ class NewContentElementController extends AbstractModule
 
             foreach ($wizardItems as $wizardKey => $wInfo) {
                 $wizardOnClick = '';
-                if ($wInfo['header']) {
+                if (isset($wInfo['header'])) {
                     $menuItems[] = [
-                        'label' => $wInfo['header'],
+                        'label' => $wInfo['header'] ?: '-',
                         'content' => ''
                     ];
                     $key = count($menuItems) - 1;