Allow translations of activerecord.errors.messages.record_invalid to be looked up in errors.messages.record_invalid
This commit is contained in:
parent
f8f66a3792
commit
4da6e1cce2
|
@ -14,7 +14,7 @@ module ActiveRecord
|
|||
def initialize(record)
|
||||
@record = record
|
||||
errors = @record.errors.full_messages.join(", ")
|
||||
super(I18n.t("activerecord.errors.messages.record_invalid", :errors => errors))
|
||||
super(I18n.t(:"#{@record.class.i18n_scope}.errors.messages.record_invalid", :errors => errors, :default => :"errors.messages.record_invalid"))
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue