summaryrefslogtreecommitdiff
path: root/db
diff options
context:
space:
mode:
authorJames Lopez <james@jameslopez.es>2018-02-03 10:42:44 +0100
committerJames Lopez <james@jameslopez.es>2018-02-03 10:42:44 +0100
commit63aa43de0ae274397ef150bf88e7f6b6be89b1d0 (patch)
tree883856ecaa327acd2d93a44fb68aeced786005e0 /db
parentb1f4dffda0bacd7bab1d79773c077568583f19e6 (diff)
downloadgitlab-ce-63aa43de0ae274397ef150bf88e7f6b6be89b1d0.tar.gz
Diffstat (limited to 'db')
-rw-r--r--db/post_migrate/20171207150300_remove_project_labels_group_id_copy.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/db/post_migrate/20171207150300_remove_project_labels_group_id_copy.rb b/db/post_migrate/20171207150300_remove_project_labels_group_id_copy.rb
index 0886a655aa2..2f339172eeb 100644
--- a/db/post_migrate/20171207150300_remove_project_labels_group_id_copy.rb
+++ b/db/post_migrate/20171207150300_remove_project_labels_group_id_copy.rb
@@ -9,9 +9,11 @@ class RemoveProjectLabelsGroupIdCopy < ActiveRecord::Migration
disable_ddl_transaction!
def up
+ # rubocop:disable Migration/UpdateColumnInBatches
update_column_in_batches(:labels, :group_id, nil) do |table, query|
query.where(table[:type].eq('ProjectLabel').and(table[:group_id].not_eq(nil)))
end
+ # rubocop:enable Migration/UpdateColumnInBatches
end
def down