Commit 0ba5e978 authored by Sean McGivern's avatar Sean McGivern Committed by GitLab Release Tools Bot

Merge branch 'dz-improve-ci-id-migration' into 'master'

Add extra checks for ci_id migration

See merge request gitlab-org/gitlab-ce!28404

(cherry picked from commit 30a60ee4)

5786de36 Add extra checks for ci_id migration
parent c9f18484
......@@ -22,7 +22,12 @@ class DropProjectsCiId < ActiveRecord::Migration[5.1]
end
def down
add_column :projects, :ci_id, :integer
add_concurrent_index :projects, :ci_id
unless column_exists?(:projects, :ci_id)
add_column :projects, :ci_id, :integer
end
unless index_exists?(:projects, :ci_id)
add_concurrent_index :projects, :ci_id
end
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment