[BUGFIX] Fix exception in FE when using predefined admPanel config 23/54123/2
authorMarkus Klein <markus.klein@typo3.org>
Mon, 11 Sep 2017 11:14:27 +0000 (13:14 +0200)
committerGeorg Ringer <georg.ringer@gmail.com>
Thu, 21 Sep 2017 06:51:36 +0000 (08:51 +0200)
Enforcing the admPanel for users via user TSconfig is working again
without crashing the FE.

We make sure that when the admPanel configuration is fetched, we
do not fall back to the toplevel value if the requested sub-value
does not exist.

Resolves: #82460
Releases: master, 8.7, 7.6
Change-Id: Ibd288805aa6c91d74eee8a9c80ebcce62d1f860f
Reviewed-on: https://review.typo3.org/54123
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Joerg Boesche <typo3@joergboesche.de>
Reviewed-by: Stefan Neufeind <typo3.neufeind@speedpartner.de>
Reviewed-by: Susanne Moog <susanne.moog@typo3.org>
Tested-by: Susanne Moog <susanne.moog@typo3.org>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
typo3/sysext/frontend/Classes/View/AdminPanelView.php

index 9337edd..2832fcf 100644 (file)
@@ -212,7 +212,7 @@ class AdminPanelView
         if ($val && isset($beUser->extAdminConfig['override.'][$sectionName . '.'][$val])) {
             return $beUser->extAdminConfig['override.'][$sectionName . '.'][$val];
         }
-        if (isset($beUser->extAdminConfig['override.'][$sectionName])) {
+        if (!$val && isset($beUser->extAdminConfig['override.'][$sectionName])) {
             return $beUser->extAdminConfig['override.'][$sectionName];
         }