diff --git a/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php b/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php index a32ebad491b2efb98fa6db40d81ad55c82356388..04a94d4e3ca6873fbdec5a4a499681a494e03c1a 100644 --- a/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php +++ b/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php @@ -3174,9 +3174,9 @@ class TypoScriptFrontendController implements LoggerAwareInterface * Sets the cache-flag to 1. Could be called from user-included php-files in order to ensure that a page is not cached. * * @param string $reason An optional reason to be written to the log. - * @param bool $internal Whether the call is done from core itself (should only be used by core). + * @param bool $internalRequest Whether the request is internal or not (true should only be used by core calls). */ - public function set_no_cache($reason = '', $internal = false) + public function set_no_cache($reason = '', $internalRequest = false) { $context = []; if ($reason !== '') { @@ -3196,18 +3196,14 @@ class TypoScriptFrontendController implements LoggerAwareInterface $context['file'] = $file; $context['line'] = $trace[0]['line']; } - if (!$internal && $GLOBALS['TYPO3_CONF_VARS']['FE']['disableNoCacheParameter']) { + if (!$internalRequest && $GLOBALS['TYPO3_CONF_VARS']['FE']['disableNoCacheParameter']) { $warning .= ' However, $TYPO3_CONF_VARS[\'FE\'][\'disableNoCacheParameter\'] is set, so it will be ignored!'; - $this->getTimeTracker()->setTSlogMessage($warning, LogLevel::WARNING); + $this->getTimeTracker()->setTSlogMessage($warning, LogLevel::NOTICE); } else { $warning .= ' Caching is disabled!'; $this->disableCache(); } - if ($internal && ($this->isBackendUserLoggedIn() || $this->isInPreviewMode())) { - $this->logger->notice($warning, $context); - } else { - $this->logger->warning($warning, $context); - } + $this->logger->notice($warning, $context); } /**