From ee2cee9dbde58d6a19d0bdf61fe1f9ac816932f1 Mon Sep 17 00:00:00 2001 From: Georg Ringer Date: Sat, 17 Mar 2018 19:58:07 +0100 Subject: [PATCH] [TASK] Remove superfluous admin check As the scheduler module is only accessible for admins, there is no need to check this in the controller. Resolves: #84454 Releases: master Change-Id: I234872820faa7c729a52c030383f6b24e6c1eca5 Reviewed-on: https://review.typo3.org/56335 Tested-by: TYPO3com Reviewed-by: Wouter Wolters Reviewed-by: Jan Helke Tested-by: Jan Helke Reviewed-by: Christian Kuhn Tested-by: Christian Kuhn --- .../Controller/SchedulerModuleController.php | 24 +++++++------------ 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php b/typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php index 1cbaac0ede29..dc4d8f343a9a 100644 --- a/typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php +++ b/typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php @@ -160,21 +160,15 @@ public function mainAction(ServerRequestInterface $request): ResponseInterface ] ]; $this->MOD_SETTINGS = BackendUtility::getModuleData($this->MOD_MENU, GeneralUtility::_GP('SET'), 'system_txschedulerM1', '', '', ''); - // Access check! - // The page will show only if user has admin rights - if ($this->getBackendUser()->isAdmin()) { - // Set the form - $content = '
'; - - // Prepare main content - $content .= '

' . $this->getLanguageService()->getLL('function.' . $this->MOD_SETTINGS['function']) . '

'; - $content .= $this->getModuleContent(); - $content .= '
'; - } else { - // If no access, only display the module's title - $content = '

' . $this->getLanguageService()->getLL('title.') . '

'; - $content .= '
'; - } + + // Set the form + $content = '
'; + + // Prepare main content + $content .= '

' . $this->getLanguageService()->getLL('function.' . $this->MOD_SETTINGS['function']) . '

'; + $content .= $this->getModuleContent(); + $content .= '
'; + $this->getButtons(); $this->getModuleMenu();