From f66bfb58fde1ae5a78f6ffcdb3a1ef9da850b870 Mon Sep 17 00:00:00 2001
From: Marco Huber <mail@marco-huber.de>
Date: Fri, 29 Jan 2016 16:29:57 +0100
Subject: [PATCH] [BUGFIX] Check access to cshmanual module

Don't render the "more" link in the help popup if the user has no
access to the cshmanual module.

Resolves: #73013
Related: #73009
Releases: master, 7.6
Change-Id: I5b236c08fd505c1f405a3fc0e459c1ac21fbeb84
Reviewed-on: https://review.typo3.org/46358
Reviewed-by: Daniel Goerz <ervaude@gmail.com>
Tested-by: Daniel Goerz <ervaude@gmail.com>
Reviewed-by: Gianluigi Martino <gmartino27@gmail.com>
Tested-by: Gianluigi Martino <gmartino27@gmail.com>
Reviewed-by: Andreas Fernandez <typo3@scripting-base.de>
Tested-by: Andreas Fernandez <typo3@scripting-base.de>
---
 typo3/sysext/backend/Classes/Utility/BackendUtility.php | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/typo3/sysext/backend/Classes/Utility/BackendUtility.php b/typo3/sysext/backend/Classes/Utility/BackendUtility.php
index 9ecba2acf0eb..c33617550f67 100755
--- a/typo3/sysext/backend/Classes/Utility/BackendUtility.php
+++ b/typo3/sysext/backend/Classes/Utility/BackendUtility.php
@@ -2448,8 +2448,10 @@ class BackendUtility
             if ($data['alttitle']) {
                 $output['title'] = $data['alttitle'];
             }
-            // If we have more information to show
-            if ($data['image_descr'] || $data['seeAlso'] || $data['details'] || $data['syntax']) {
+            // If we have more information to show and access to the cshmanual
+            if (($data['image_descr'] || $data['seeAlso'] || $data['details'] || $data['syntax'])
+                && static::getBackendUserAuthentication()->check('modules', 'help_CshmanualCshmanual')
+            ) {
                 $output['moreInfo'] = true;
             }
             // Add description
-- 
GitLab