[BUGFIX] Keep selected page active after save & close 70/47070/2
authorGianluigi Martino <gmartino27@gmail.com>
Thu, 3 Mar 2016 21:32:01 +0000 (22:32 +0100)
committerJan Helke <typo3@helke.de>
Fri, 4 Mar 2016 17:56:41 +0000 (18:56 +0100)
Keep the currently selected page active when editing the page properties
of another page as non-admin user.

Change-Id: Iad438ad7e20ab8d818286053557ade26542d8216
Reviewed-on: https://review.typo3.org/47070
Reviewed-by: Jan Helke <typo3@helke.de>
Tested-by: Jan Helke <typo3@helke.de>
typo3/sysext/backend/Classes/Tree/Pagetree/ExtdirectTreeCommands.php

index 2571397..223809b 100644 (file)
@@ -358,7 +358,9 @@ class ExtdirectTreeCommands
         if (empty($mountPoints)) {
             $mountPoints = array(0);
         }
-        $mountPoints[] = (int)$GLOBALS['BE_USER']->uc['pageTree_temporaryMountPoint'];
+        if (!empty($GLOBALS['BE_USER']->uc['pageTree_temporaryMountPoint'])){
+            $mountPoints[] = (int)$GLOBALS['BE_USER']->uc['pageTree_temporaryMountPoint'];
+        }
         $mountPoints = array_unique($mountPoints);
         /** @var $userSettingsController \TYPO3\CMS\Backend\Controller\UserSettingsController */
         $userSettingsController = GeneralUtility::makeInstance(\TYPO3\CMS\Backend\Controller\UserSettingsController::class);