[BUGFIX] Shortcut icons now check permissions 74/35874/3
authorWouter Wolters <typo3@wouterwolters.nl>
Wed, 7 Jan 2015 18:22:41 +0000 (19:22 +0100)
committerStefan Froemken <froemken@gmail.com>
Thu, 8 Jan 2015 17:43:23 +0000 (18:43 +0100)
Resolves: #36193
Releases: master, 6.2
Change-Id: Idcce6744d1b3d108daafb47103beefaf8d61c27c
Reviewed-on: http://review.typo3.org/35874
Reviewed-by: Markus Klein <klein.t3@reelworx.at>
Tested-by: Markus Klein <klein.t3@reelworx.at>
Reviewed-by: Benjamin Mack <benni@typo3.org>
Tested-by: Stefan Froemken <froemken@gmail.com>
typo3/sysext/fluid/Classes/ViewHelpers/Be/Buttons/ShortcutViewHelper.php

index a2dff26..7728c5e 100644 (file)
@@ -56,9 +56,9 @@ class ShortcutViewHelper extends \TYPO3\CMS\Fluid\ViewHelpers\Be\AbstractBackend
         * @see \TYPO3\CMS\Backend\Template\DocumentTemplate::makeShortcutIcon()
         */
        public function render(array $getVars = array(), array $setVars = array()) {
-               $enableBookmarks = $GLOBALS['BE_USER']->getTSConfigVal('options.enableBookmarks');
+               $mayMakeShortcut = $GLOBALS['BE_USER']->mayMakeShortcut();
 
-               if ($enableBookmarks) {
+               if ($mayMakeShortcut) {
                        $doc = $this->getDocInstance();
                        $currentRequest = $this->controllerContext->getRequest();
                        $extensionName = $currentRequest->getControllerExtensionName();