Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authormicael.bergeron <micaelbergeron@gmail.com>2017-11-06 18:20:20 +0300
committermicael.bergeron <micaelbergeron@gmail.com>2017-11-06 18:20:20 +0300
commitd934d6504a9f1a706dbfc0b4a28c4cf8dbe8c8eb (patch)
tree0eb1d96ae44f2394c1dfb3bcb5a22af4802acccf /app
parent5ab3ed7a9ad16ad20fd3341a02b597697644ea3f (diff)
updated the ignore_column concern to support multiple columns
This method is an ActiveRecord extension and it should behave like one. I expected this to work.
Diffstat (limited to 'app')
-rw-r--r--app/models/concerns/ignorable_column.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/models/concerns/ignorable_column.rb b/app/models/concerns/ignorable_column.rb
index eb9f3423e48..03793e8bcbb 100644
--- a/app/models/concerns/ignorable_column.rb
+++ b/app/models/concerns/ignorable_column.rb
@@ -21,8 +21,8 @@ module IgnorableColumn
@ignored_columns ||= Set.new
end
- def ignore_column(name)
- ignored_columns << name.to_s
+ def ignore_column(*names)
+ ignored_columns.merge(names.map(&:to_s))
end
end
end