[TASK] Deprecate TSFE->checkFileInclude 20/38020/3
authorBenjamin Mack <benni@typo3.org>
Mon, 23 Mar 2015 01:10:40 +0000 (02:10 +0100)
committerBenjamin Mack <benni@typo3.org>
Mon, 23 Mar 2015 15:50:26 +0000 (16:50 +0100)
The file inclusion logic within the TypoScriptFrontendController
is not used anymore and can safely be deprecated.

Resolves: #65913
Releases: master
Change-Id: Ib229fd25a560fc2a0520032cb6bc9a358a5b69df
Reviewed-on: http://review.typo3.org/38020
Reviewed-by: Nicole Cordes <typo3@cordes.co>
Tested-by: Nicole Cordes <typo3@cordes.co>
Reviewed-by: Jan Helke <typo3@helke.de>
Tested-by: Jan Helke <typo3@helke.de>
Reviewed-by: Benjamin Mack <benni@typo3.org>
Tested-by: Benjamin Mack <benni@typo3.org>
typo3/sysext/core/Documentation/Changelog/master/Deprecation-65913-checkFileInclude.rst [new file with mode: 0644]
typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php

diff --git a/typo3/sysext/core/Documentation/Changelog/master/Deprecation-65913-checkFileInclude.rst b/typo3/sysext/core/Documentation/Changelog/master/Deprecation-65913-checkFileInclude.rst
new file mode 100644 (file)
index 0000000..bb456fd
--- /dev/null
@@ -0,0 +1,20 @@
+=======================================================
+Deprecation: #65913 - Deprecate $TSFE->checkFileInclude
+=======================================================
+
+Description
+===========
+
+The public method in the global frontend controller ``$TSFE->checkFileInclude()`` has been marked as deprecated.
+
+
+Affected installations
+======================
+
+Instances with extensions that make use of the method directly.
+
+
+Migration
+=========
+
+Use the autoloader for classes or ``$TSFE->tmpl->getFileName()`` if needed.
index 3165614..91ae203 100644 (file)
@@ -3877,9 +3877,10 @@ class TypoScriptFrontendController {
         *
         * @param string $incFile Relative path to php file
         * @return bool Returns TRUE if $GLOBALS['TYPO3_CONF_VARS']['FE']['noPHPscriptInclude'] is not set OR if the file requested for inclusion is found in one of the allowed paths.
-        * @see \TYPO3\CMS\Frontend\ContentObject\Menu\AbstractMenuContentObject::includeMakeMenu()
+        * @deprecated since TYPO3 CMS 7, will be removed with TYPO3 CMS 8
         */
        public function checkFileInclude($incFile) {
+               GeneralUtility::logDeprecatedFunction();
                return !$this->TYPO3_CONF_VARS['FE']['noPHPscriptInclude'] || substr($incFile, 0, 4 + strlen(TYPO3_mainDir)) == TYPO3_mainDir . 'ext/' || substr($incFile, 0, 7 + strlen(TYPO3_mainDir)) == TYPO3_mainDir . 'sysext/' || substr($incFile, 0, 14) == 'typo3conf/ext/';
        }