Commit 0832c91f authored by Stan Hu's avatar Stan Hu

Append to self.ignored_columns instead of setting

parent b7ebf8a9
......@@ -31,7 +31,7 @@ class ApplicationSetting < ApplicationRecord
serialize :repository_storages # rubocop:disable Cop/ActiveRecordSerialize
serialize :asset_proxy_whitelist, Array # rubocop:disable Cop/ActiveRecordSerialize
self.ignored_columns = %i[
self.ignored_columns += %i[
clientside_sentry_dsn
clientside_sentry_enabled
koding_enabled
......
......@@ -17,7 +17,7 @@ module Ci
BuildArchivedError = Class.new(StandardError)
self.ignored_columns = %i[
self.ignored_columns += %i[
artifacts_file
artifacts_file_store
artifacts_metadata
......
......@@ -35,7 +35,7 @@ module Ci
FORM_EDITABLE = %i[description tag_list active run_untagged locked access_level maximum_timeout_human_readable].freeze
self.ignored_columns = %i[is_shared]
self.ignored_columns += %i[is_shared]
has_many :builds
has_many :runner_projects, inverse_of: :runner, dependent: :destroy # rubocop:disable Cop/ActiveRecordDependent
......
......@@ -10,7 +10,7 @@ class DeployKey < Key
scope :are_public, -> { where(public: true) }
scope :with_projects, -> { includes(deploy_keys_projects: { project: [:route, :namespace] }) }
self.ignored_columns = %i[can_push]
self.ignored_columns += %i[can_push]
accepts_nested_attributes_for :deploy_keys_projects
......
......@@ -33,7 +33,7 @@ class Note < ApplicationRecord
end
end
self.ignored_columns = %i[original_discussion_id]
self.ignored_columns += %i[original_discussion_id]
cache_markdown_field :note, pipeline: :note, issuable_state_filter_enabled: true
......
# frozen_string_literal: true
class NotificationSetting < ApplicationRecord
self.ignored_columns = %i[events]
self.ignored_columns += %i[events]
enum level: { global: 3, watch: 2, participating: 1, mention: 4, disabled: 0, custom: 5 }
......
......@@ -23,7 +23,7 @@ class User < ApplicationRecord
DEFAULT_NOTIFICATION_LEVEL = :participating
self.ignored_columns = %i[
self.ignored_columns += %i[
authentication_token
email_provider
external_email
......
......@@ -50,7 +50,7 @@ places. This can be done by defining the columns to ignore. For example, to igno
```ruby
class User < ApplicationRecord
self.ignored_columns = %i[updated_at]
self.ignored_columns += %i[updated_at]
end
```
......
......@@ -14,7 +14,7 @@ module EE
belongs_to :file_template_project, class_name: "Project"
self.ignored_columns = %i[minimum_mirror_sync_time]
self.ignored_columns += %i[minimum_mirror_sync_time]
validates :shared_runners_minutes,
numericality: { greater_than_or_equal_to: 0 }
......
......@@ -21,7 +21,7 @@ module EE
include InsightsFeature
include Vulnerable
self.ignored_columns = %i[
self.ignored_columns += %i[
mirror_last_update_at
mirror_last_successful_update_at
next_execution_timestamp
......
......@@ -6,7 +6,7 @@ module EE
extend ::Gitlab::Utils::Override
prepended do
self.ignored_columns = %i[created_at updated_at]
self.ignored_columns += %i[created_at updated_at]
BACKOFF_PERIOD = 24.seconds
JITTER = 6.seconds
......
......@@ -18,7 +18,7 @@ module EE
prepended do
EMAIL_OPT_IN_SOURCE_ID_GITLAB_COM = 1
self.ignored_columns = %i[support_bot]
self.ignored_columns += %i[support_bot]
# We aren't using the `auditor?` method for the `if` condition here
# because `auditor?` returns `false` when the `auditor` column is `true`
......
......@@ -3,7 +3,7 @@
class ProjectRepositoryState < ApplicationRecord
include ShaAttribute
self.ignored_columns = %i[last_repository_verification_failed last_wiki_verification_failed]
self.ignored_columns += %i[last_repository_verification_failed last_wiki_verification_failed]
sha_attribute :repository_verification_checksum
sha_attribute :wiki_verification_checksum
......
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