From 3dd9dbf757de71879330782e6ea8a52495acc956 Mon Sep 17 00:00:00 2001 From: Gerhard Schlager Date: Sun, 6 Sep 2015 21:20:16 +0200 Subject: [PATCH] Remove hard-coded fallback to English locale In production mode the English locale is always used as fallback. In development mode there is currently no fallback, so the English locale isn't loaded and the second call to I18n.l() fails too. --- app/mailers/user_notifications.rb | 3 --- 1 file changed, 3 deletions(-) diff --git a/app/mailers/user_notifications.rb b/app/mailers/user_notifications.rb index 438e63f6f30..52e91f644da 100644 --- a/app/mailers/user_notifications.rb +++ b/app/mailers/user_notifications.rb @@ -41,11 +41,8 @@ class UserNotifications < ActionMailer::Base build_email( user.email, template: "user_notifications.account_created", email_token: opts[:email_token]) end - # On error, use english def short_date(dt) I18n.l(dt, format: :short) - rescue I18n::MissingTranslationData - I18n.l(dt, format: :short, locale: 'en') end def digest(user, opts={})