workaround from https://rails.lighthouseapp.com/projects/8994/tickets/5329-using-i18nwith_locale-in-actionmailer-raises-systemstackerror
This commit is contained in:
parent
e76c5068d1
commit
cd2d7db7b2
1 changed files with 10 additions and 0 deletions
|
|
@ -14,3 +14,13 @@ AVAILABLE_LANGUAGE_CODES.each do |c|
|
|||
I18n.fallbacks[c.to_sym] = [c.to_sym, DEFAULT_LANGUAGE.to_sym, :en]
|
||||
end
|
||||
end
|
||||
|
||||
# Workaround for https://rails.lighthouseapp.com/projects/8994/tickets/5329-using-i18nwith_locale-in-actionmailer-raises-systemstackerror
|
||||
module AbstractController
|
||||
class I18nProxy
|
||||
def initialize(i18n_config, lookup_context)
|
||||
@i18n_config, @lookup_context = i18n_config, lookup_context
|
||||
@i18n_config = @i18n_config.i18n_config if @i18n_config.respond_to?(:i18n_config)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in a new issue