Skip to content
Snippets Groups Projects
Commit 76a5fa11 authored by Morris Jobke's avatar Morris Jobke
Browse files

Merge pull request #9741 from owncloud/fix-repair-innodb-9737-master

check if $tables is an array
parents 8cd1f746 f0c0bd52
No related branches found
No related tags found
Loading
......@@ -28,9 +28,11 @@ class InnoDB extends BasicEmitter implements \OC\RepairStep {
}
$tables = $this->getAllMyIsamTables($connection);
foreach ($tables as $table) {
$connection->exec("ALTER TABLE $table ENGINE=InnoDB;");
$this->emit('\OC\Repair', 'info', array("Fixed $table"));
if (is_array($tables)) {
foreach ($tables as $table) {
$connection->exec("ALTER TABLE $table ENGINE=InnoDB;");
$this->emit('\OC\Repair', 'info', array("Fixed $table"));
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment