From 0e5c8e23bdfa024c430a80d7b6dd7fa68d2ca06a Mon Sep 17 00:00:00 2001 From: Godwin Date: Wed, 29 Jun 2016 16:34:52 -0700 Subject: [PATCH] Fixed i18n redirection in prod --- app/controllers/application_controller.rb | 2 ++ config/environments/production.rb | 1 - 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index ba200b1..e30f843 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -43,6 +43,8 @@ class ApplicationController < LinguaFrancaApplicationController @alt_lang_urls[locale] = view_context.url_for_locale(locale) # don't show the current locale end + xxx + # call the base method to detect the language super end diff --git a/config/environments/production.rb b/config/environments/production.rb index fe85d2e..c10c435 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -100,5 +100,4 @@ BikeBike::Application.configure do config.action_mailer.raise_delivery_errors = true config.action_mailer.perform_deliveries = true I18n.config.language_detection_method = I18n::Config::DETECT_LANGUAGE_FROM_SUBDOMAIN - I18n.config.host_locale_regex = /^preview\-([a-z]{2})\.bikebike\.org$/ end