summaryrefslogtreecommitdiff
path: root/db/migrate/20151019111703_fail_build_without_names.rb
diff options
context:
space:
mode:
authorValery Sizov <valery@gitlab.com>2015-11-05 16:41:03 +0200
committerValery Sizov <valery@gitlab.com>2015-11-05 16:47:25 +0200
commitaecc4376e20b3ad23662f6181a776ac5747baa06 (patch)
tree47d4932661400a006d8373400e71295108873d51 /db/migrate/20151019111703_fail_build_without_names.rb
parent4f574388fc8594ec6f6e9d719f524912d17c4059 (diff)
downloadgitlab-ce-aecc4376e20b3ad23662f6181a776ac5747baa06.tar.gz
make migrations reversible
Diffstat (limited to 'db/migrate/20151019111703_fail_build_without_names.rb')
-rw-r--r--db/migrate/20151019111703_fail_build_without_names.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/db/migrate/20151019111703_fail_build_without_names.rb b/db/migrate/20151019111703_fail_build_without_names.rb
index 546b03d8129..dcdb5d1b25d 100644
--- a/db/migrate/20151019111703_fail_build_without_names.rb
+++ b/db/migrate/20151019111703_fail_build_without_names.rb
@@ -1,5 +1,8 @@
class FailBuildWithoutNames < ActiveRecord::Migration
- def change
+ def up
execute("UPDATE ci_builds SET status='failed' WHERE name IS NULL AND status='pending'")
end
+
+ def down
+ end
end