[BUGFIX] Extension Upload ends in PHP Error 41/26741/4
authorRico Sonntag <rico.sonntag@netresearch.de>
Fri, 10 Jan 2014 14:12:08 +0000 (15:12 +0100)
committerMarkus Klein <klein.t3@mfc-linz.at>
Mon, 17 Feb 2014 12:45:47 +0000 (13:45 +0100)
Adds an additional check after processing of the ext_emconf.php, throwing
an exception if EmConfUtility::includeEmConf returns FALSE.

Change-Id: Ib1404e2911b8372c5d8ff99aaf2e6313eaf7e157
Fixes: #53210
Releases: 6.2
Reviewed-on: https://review.typo3.org/26741
Reviewed-by: Markus Klein
Tested-by: Markus Klein
typo3/sysext/extensionmanager/Classes/Utility/InstallUtility.php

index c808260..878992c 100644 (file)
@@ -207,6 +207,14 @@ class InstallUtility implements \TYPO3\CMS\Core\SingletonInterface {
                        throw new \TYPO3\CMS\Extensionmanager\Exception\ExtensionManagerException('Extension ' . $extensionKey . ' is not available', 1342864081);
                }
                $availableAndInstalledExtensions = $this->listUtility->enrichExtensionsWithEmConfAndTerInformation(array($extensionKey => $extension));
+
+               if (!isset($availableAndInstalledExtensions[$extensionKey])) {
+                       throw new \TYPO3\CMS\Extensionmanager\Exception\ExtensionManagerException(
+                               'Please check your uploaded extension "' . $extensionKey . '". The configuration file "ext_emconf.php" seems to be invalid.',
+                               1391432222
+                       );
+               }
+
                return $availableAndInstalledExtensions[$extensionKey];
        }