aboutsummaryrefslogtreecommitdiffstats
path: root/activemodel/lib
diff options
context:
space:
mode:
authorMartin Larochelle <martin.larochelle@shopify.com>2018-08-16 11:07:56 -0400
committerMartin Larochelle <martin.larochelle@shopify.com>2018-08-16 11:50:13 -0400
commit8d2f3179e6f312b34a2bacf36bc74f9c24e751bd (patch)
tree817ea930fe5fda360295c7be6a928fea2fec003a /activemodel/lib
parent0b54641878a9cee450170135ca0c43ddbb4cb09f (diff)
downloadrails-8d2f3179e6f312b34a2bacf36bc74f9c24e751bd.tar.gz
rails-8d2f3179e6f312b34a2bacf36bc74f9c24e751bd.tar.bz2
rails-8d2f3179e6f312b34a2bacf36bc74f9c24e751bd.zip
Call human_attribute_name with a string instead of a symbole
Diffstat (limited to 'activemodel/lib')
-rw-r--r--activemodel/lib/active_model/errors.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activemodel/lib/active_model/errors.rb b/activemodel/lib/active_model/errors.rb
index 5138a07b71..af94d52d45 100644
--- a/activemodel/lib/active_model/errors.rb
+++ b/activemodel/lib/active_model/errors.rb
@@ -413,7 +413,7 @@ module ActiveModel
defaults << "%{attribute} %{message}"
attr_name = attribute.tr(".", "_").humanize
- attr_name = @base.class.human_attribute_name(attribute.to_sym, default: attr_name)
+ attr_name = @base.class.human_attribute_name(attribute, default: attr_name)
I18n.t(defaults.shift,
default: defaults,