mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Merge pull request #34862 from bogdanvlviv/fix-i18n-guide
Fix example of I18n setting in the guide [ci skip]
This commit is contained in:
commit
de50002723
1 changed files with 1 additions and 1 deletions
|
@ -299,7 +299,7 @@ A trivial implementation of using an `Accept-Language` header would be:
|
|||
def switch_locale(&action)
|
||||
logger.debug "* Accept-Language: #{request.env['HTTP_ACCEPT_LANGUAGE']}"
|
||||
locale = extract_locale_from_accept_language_header
|
||||
logger.debug "* Locale set to '#{I18n.locale}'"
|
||||
logger.debug "* Locale set to '#{locale}'"
|
||||
I18n.with_locale(locale, &action)
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue