diff options
author | Jason Robinson <mail@jasonrobinson.me> | 2015-05-12 22:19:00 +0300 |
---|---|---|
committer | Dennis Schubert <mail@dennis-schubert.de> | 2015-05-16 04:40:06 +0300 |
commit | ce16a122fcb0283f2af47e3e1aa379af4449e591 (patch) | |
tree | 51f24286f07d27ee92488bf4694e854321078f99 /app/mailers | |
parent | aec2467e9895a4e70240274d1174f10218113d8d (diff) |
Fix missing localization of inactive user removal warning emails.
Fixes #5950
Diffstat (limited to 'app/mailers')
-rw-r--r-- | app/mailers/maintenance.rb | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/app/mailers/maintenance.rb b/app/mailers/maintenance.rb index 052fd7c78..6b0f2e07b 100644 --- a/app/mailers/maintenance.rb +++ b/app/mailers/maintenance.rb @@ -7,9 +7,12 @@ class Maintenance < ActionMailer::Base @pod_url = AppConfig.environment.url @after_days = AppConfig.settings.maintenance.remove_old_users.after_days.to_s @remove_after = @user.remove_after - mail(:to => @user.email, :subject => I18n.t('notifier.remove_old_user.subject')) do |format| - format.text - format.html + + I18n.with_locale(@user.language) do + mail(to: @user.email, subject: I18n.t("notifier.remove_old_user.subject")) do |format| + format.text + format.html + end end end end |