FIX: prevent unnecessary field alterations for enums with empty defaults

This commit is contained in:
Loz Calver 2019-04-05 16:17:41 +01:00
parent e9fe68c06c
commit 594af77134

View File

@ -284,7 +284,7 @@ class MySQLSchemaManager extends DBSchemaManager
$fieldSpec .= " character set $collInfo[Charset] collate $field[Collation]";
}
if ($field['Default'] || $field['Default'] === "0") {
if ($field['Default'] || $field['Default'] === "0" || $field['Default'] === '') {
$fieldSpec .= " default " . $this->database->quoteString($field['Default']);
}
if ($field['Extra']) {