diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-07-23 17:40:44 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2014-07-23 17:40:44 -0300 |
commit | cd7d414e48f537278043bfc77cfb4217e8c89c24 (patch) | |
tree | 24e1adf269ec4e4b38532204d52105e70c7afc1d /activesupport/lib | |
parent | af216b743199f5179e20d0aa536fac5d44067969 (diff) | |
download | rails-cd7d414e48f537278043bfc77cfb4217e8c89c24.tar.gz rails-cd7d414e48f537278043bfc77cfb4217e8c89c24.tar.bz2 rails-cd7d414e48f537278043bfc77cfb4217e8c89c24.zip |
Do not set enforce_available_locales to i18n 0.7
Now the default is always true.
Users still can set it using config.i18n.enforce_available_locales.
Diffstat (limited to 'activesupport/lib')
-rw-r--r-- | activesupport/lib/active_support/i18n_railtie.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/activesupport/lib/active_support/i18n_railtie.rb b/activesupport/lib/active_support/i18n_railtie.rb index 23cd6716e3..affcfb7398 100644 --- a/activesupport/lib/active_support/i18n_railtie.rb +++ b/activesupport/lib/active_support/i18n_railtie.rb @@ -8,8 +8,6 @@ module I18n config.i18n.railties_load_path = [] config.i18n.load_path = [] config.i18n.fallbacks = ActiveSupport::OrderedOptions.new - # Enforce I18n to check the available locales when setting a locale. - config.i18n.enforce_available_locales = true # Set the i18n configuration after initialization since a lot of # configuration is still usually done in application initializers. @@ -36,7 +34,7 @@ module I18n # Avoid issues with setting the default_locale by disabling available locales # check while configuring. enforce_available_locales = app.config.i18n.delete(:enforce_available_locales) - enforce_available_locales = I18n.enforce_available_locales unless I18n.enforce_available_locales.nil? + enforce_available_locales = I18n.enforce_available_locales if enforce_available_locales.nil? I18n.enforce_available_locales = false app.config.i18n.each do |setting, value| |