Merge pull request #3734 from gschlager/i18n-2
Remove hard-coded fallback to English locale
This commit is contained in:
commit
6850476cb3
|
@ -41,11 +41,8 @@ class UserNotifications < ActionMailer::Base
|
||||||
build_email( user.email, template: "user_notifications.account_created", email_token: opts[:email_token])
|
build_email( user.email, template: "user_notifications.account_created", email_token: opts[:email_token])
|
||||||
end
|
end
|
||||||
|
|
||||||
# On error, use english
|
|
||||||
def short_date(dt)
|
def short_date(dt)
|
||||||
I18n.l(dt, format: :short)
|
I18n.l(dt, format: :short)
|
||||||
rescue I18n::MissingTranslationData
|
|
||||||
I18n.l(dt, format: :short, locale: 'en')
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def digest(user, opts={})
|
def digest(user, opts={})
|
||||||
|
|
Loading…
Reference in New Issue