[TASK] Streamline addModulePath call 25/42725/2
authorBenjamin Mack <benni@typo3.org>
Tue, 18 Aug 2015 18:03:19 +0000 (20:03 +0200)
committerAnja Leichsenring <aleichsenring@ab-softlab.de>
Tue, 18 Aug 2015 18:18:35 +0000 (20:18 +0200)
The addModulePath functionality is also copied inside
addModule in ExtensionManagementUtility and can be reused.

During that, the EXT:recordlist/ext_tables.php call, is duplicated
and addModulePath can be removed there.

Releases: master
Resolves: #69165
Change-Id: I92dd5b566283d4114216242bf297ef42d6b709a0
Reviewed-on: http://review.typo3.org/42725
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
typo3/sysext/core/Classes/Utility/ExtensionManagementUtility.php
typo3/sysext/recordlist/ext_tables.php

index eca3b5e..be81fb8 100644 (file)
@@ -916,12 +916,7 @@ class ExtensionManagementUtility {
                $fullModuleSignature = $main . ($sub ? '_' . $sub : '');
                // Adding path:
                if ($path) {
-                       if (\TYPO3\CMS\Core\Utility\StringUtility::beginsWith($path, 'EXT:')) {
-                               list($extensionKey, $relativePath) = explode('/', substr($path, 4), 2);
-                               $path = ExtensionManagementUtility::extPath($extensionKey) . $relativePath;
-                       }
-
-                       $GLOBALS['TBE_MODULES']['_PATHS'][$fullModuleSignature] = $path;
+                       self::addModulePath($fullModuleSignature, $path);
                }
 
                // add additional configuration
index 107d003..91e29be 100644 (file)
@@ -2,10 +2,6 @@
 defined('TYPO3_MODE') or die();
 
 if (TYPO3_MODE === 'BE') {
-       \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addModulePath(
-               'web_list',
-               'EXT:recordlist/Modules/Recordlist/'
-       );
        \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addModule(
                'web',
                'list',