From e1a7f83fca862fd7472ef6b80f8b6a8d33849a8e Mon Sep 17 00:00:00 2001 From: Sven Fuchs Date: Fri, 4 Jul 2008 22:22:20 +0200 Subject: use :default for human_attribute_name --- activerecord/lib/active_record/validations.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activerecord/lib/active_record/validations.rb') diff --git a/activerecord/lib/active_record/validations.rb b/activerecord/lib/active_record/validations.rb index 5245f65869..8ba09b3992 100755 --- a/activerecord/lib/active_record/validations.rb +++ b/activerecord/lib/active_record/validations.rb @@ -168,7 +168,7 @@ module ActiveRecord full_messages << message else key = :"active_record.human_attribute_names.#{@base.class.name.underscore.to_sym}.#{attr}" - attr_name = I18n.translate(key, locale, :raise => true) rescue @base.class.human_attribute_name(attr) + attr_name = I18n.translate(key, locale, :default => @base.class.human_attribute_name(attr)) full_messages << attr_name + " " + message end end -- cgit v1.2.3