From ba16fd2b24db479bf5d0d73bd51fdc711302dfbd Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim=20D=C3=BCsterhus?= Date: Wed, 23 Dec 2020 12:26:44 +0100 Subject: [PATCH] Create all tables as InnoDB in MySQLDatabaseEditor::createTable() Resolves #3404. --- .../lib/system/database/editor/MySQLDatabaseEditor.class.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/wcfsetup/install/files/lib/system/database/editor/MySQLDatabaseEditor.class.php b/wcfsetup/install/files/lib/system/database/editor/MySQLDatabaseEditor.class.php index bfa81d7e40..16f0fe1fed 100644 --- a/wcfsetup/install/files/lib/system/database/editor/MySQLDatabaseEditor.class.php +++ b/wcfsetup/install/files/lib/system/database/editor/MySQLDatabaseEditor.class.php @@ -215,11 +215,9 @@ class MySQLDatabaseEditor extends DatabaseEditor { } // build index definition - $hasFulltextIndex = false; foreach ($indices as $index) { if (!empty($indexDefinition)) $indexDefinition .= ','; $indexDefinition .= $this->buildIndexDefinition($index['name'], $index['data']); - if ($index['data']['type'] == 'FULLTEXT') $hasFulltextIndex = true; } // create table @@ -227,7 +225,7 @@ class MySQLDatabaseEditor extends DatabaseEditor { ".$columnDefinition." ".(!empty($indexDefinition) ? ',' : '')." ".$indexDefinition." - ) ENGINE=".($hasFulltextIndex ? 'MyISAM' : 'InnoDB')." DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci"; + ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci"; $statement = $this->dbObj->prepareStatement($sql); $statement->execute(); } -- 2.20.1