Commit 7b7582b8 authored by Dylan Griffith's avatar Dylan Griffith

Merge branch '331414-remove-ignore-column-rule' into 'master'

Remove ignore_column :remove_on_close from Label model

See merge request gitlab-org/gitlab!67367
parents 0956ef50 10c96cfd
......@@ -9,10 +9,6 @@ class Label < ApplicationRecord
include Sortable
include FromUnion
include Presentable
include IgnorableColumns
# TODO: Project#create_labels can remove column exception when this column is dropped from all envs
ignore_column :remove_on_close, remove_with: '14.1', remove_after: '2021-06-22'
cache_markdown_field :description, pipeline: :single_line
......
......@@ -1427,8 +1427,7 @@ class Project < ApplicationRecord
# rubocop: disable CodeReuse/ServiceClass
def create_labels
Label.templates.each do |label|
# TODO: remove_on_close exception can be removed after the column is dropped from all envs
params = label.attributes.except('id', 'template', 'created_at', 'updated_at', 'type', 'remove_on_close')
params = label.attributes.except('id', 'template', 'created_at', 'updated_at', 'type')
Labels::FindOrCreateService.new(nil, self, params).execute(skip_authorization: true)
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