diff --git a/src/PHPCensor/Migrations/20170416130610_fixed_environments.php b/src/PHPCensor/Migrations/20170416130610_fixed_environments.php new file mode 100644 index 00000000..8c2b96b4 --- /dev/null +++ b/src/PHPCensor/Migrations/20170416130610_fixed_environments.php @@ -0,0 +1,28 @@ +table('build'); + + if ($table->hasColumn('environment')) { + $table + ->changeColumn('environment', 'string', ['limit' => 250, 'null' => true]) + ->save(); + } + } + + public function down() + { + $table = $this->table('build'); + + if ($table->hasColumn('environment')) { + $table + ->changeColumn('environment', 'string', ['limit' => 250, 'null' => false]) + ->save(); + } + } +}