Fix for 5.59 upgrade on multilingual
authorJon Goldberg <jon@megaphonetech.com>
Thu, 2 Mar 2023 15:37:09 +0000 (10:37 -0500)
committerTim Otten <totten@civicrm.org>
Sat, 4 Mar 2023 00:42:22 +0000 (16:42 -0800)
CRM/Upgrade/Incremental/Base.php

index 7e6f85142a72db9679be2b8fb0ef14414a6b5ffc..4171e4b5dc9e09a65d6f2675aaa4b1afd6fdfac5 100644 (file)
@@ -527,6 +527,10 @@ class CRM_Upgrade_Incremental_Base {
     if ($schema->isEnabled()) {
       $schema->fixSchemaDifferencesFor($table);
     }
+    $locales = CRM_Core_I18n::getMultilingual();
+    if ($locales) {
+      CRM_Core_I18n_Schema::rebuildMultilingualSchema($locales, NULL, TRUE);
+    }
     return TRUE;
   }
 
@@ -613,6 +617,9 @@ class CRM_Upgrade_Incremental_Base {
     if ($schema->isEnabled()) {
       $schema->fixSchemaDifferencesFor($table);
     }
+    if ($locales) {
+      CRM_Core_I18n_Schema::rebuildMultilingualSchema($locales, NULL, TRUE);
+    }
     return TRUE;
   }