X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/3786366fdc691320c0a2c6982fe43a8e4b80bcc6..9b19a45e74abd4414bb79d6b992f7bec14390ad6:/app/mailers/notifier.rb?ds=sidebyside diff --git a/app/mailers/notifier.rb b/app/mailers/notifier.rb index 3c794cca9..3e0ba446d 100644 --- a/app/mailers/notifier.rb +++ b/app/mailers/notifier.rb @@ -202,10 +202,8 @@ class Notifier < ApplicationMailer end end - def with_recipient_locale(recipient) - I18n.with_locale Locale.available.preferred(recipient.preferred_languages) do - yield - end + def with_recipient_locale(recipient, &block) + I18n.with_locale(Locale.available.preferred(recipient.preferred_languages), &block) end def from_address(name, type, id, digest, user_id = nil)