Fix DB migrations to allow rollbacks

This commit is contained in:
Anand Capur 2017-08-23 12:34:34 -07:00
parent 3ee5803416
commit a73e71dd81
No known key found for this signature in database
GPG key ID: D2CF19AAD5272522
2 changed files with 4 additions and 2 deletions

View file

@ -23,8 +23,8 @@ class AllowNegativeValuesForOverallocation extends Migration
public function down()
{
Schema::table('nodes', function (Blueprint $table) {
$table->mediumInteger('disk_overallocate')->unsigned()->nullable()->change();
$table->mediumInteger('memory_overallocate')->unsigned()->nullable()->change();
DB::statement('ALTER TABLE nodes MODIFY disk_overallocate MEDIUMINT UNSIGNED NULL,
MODIFY memory_overallocate MEDIUMINT UNSIGNED NULL');
});
}
}