[TASK] Prevent database error for upgrade wizard 87/42087/2
authorAnja Leichsenring <aleichsenring@ab-softlab.de>
Wed, 29 Jul 2015 12:21:43 +0000 (14:21 +0200)
committerChristian Kuhn <lolli@schwarzbu.ch>
Wed, 29 Jul 2015 21:35:59 +0000 (23:35 +0200)
The Upgrade Wizard LanguageIsoCodeUpdate relies on the usage
and therefor existence of ext:static_info_tables. If it is not
available, the upgrade wizard is not needed. It will show up
in the list anyway and cause a database error for the missing
table static_languages.
If no ext:static_info_tables is loaded, don't show the wizard.

Change-Id: I47752efcb2d2994add239ee263969ef44f88df33
Resolves: #68616
Relates: #61542
Releases: master
Reviewed-on: http://review.typo3.org/42087
Reviewed-by: Andreas Fernandez <typo3@scripting-base.de>
Tested-by: Andreas Fernandez <typo3@scripting-base.de>
Reviewed-by: Benjamin Mack <benni@typo3.org>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
typo3/sysext/install/Classes/Updates/LanguageIsoCodeUpdate.php

index 23bacc3..bd7ab44 100644 (file)
@@ -13,6 +13,7 @@ namespace TYPO3\CMS\Install\Updates;
  *
  * The TYPO3 project - inspiring people to share!
  */
+use TYPO3\CMS\Core\Utility\ExtensionManagementUtility;
 
 /**
  * Update sys_language records to use the newly created
@@ -33,7 +34,7 @@ class LanguageIsoCodeUpdate extends AbstractUpdate {
         * @return bool Whether an update is needed (TRUE) or not (FALSE)
         */
        public function checkForUpdate(&$description) {
-               if ($this->isWizardDone()) {
+               if ($this->isWizardDone() || !ExtensionManagementUtility::isLoaded('static_info_tables')) {
                        return FALSE;
                }