From b399a961a337a4f072c51c50ed950d7dde8e742e Mon Sep 17 00:00:00 2001 From: Andreas Stephanides Date: Thu, 9 Jul 2015 17:03:04 +0200 Subject: [PATCH] AutoCommit Don Jul 9 17:03:04 CEST 2015 --- app/controllers/home_controller.rb | 1 + app/helpers/application_helper.rb | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/controllers/home_controller.rb b/app/controllers/home_controller.rb index 0d30d5d..630356e 100755 --- a/app/controllers/home_controller.rb +++ b/app/controllers/home_controller.rb @@ -95,6 +95,7 @@ class HomeController < ApplicationController end end def language + redirect_to request.referer || root_path end def choose_contact_topics authorize! :doadmin, User diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 9bcb565..bf8855d 100755 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -39,8 +39,8 @@ m.save def switch_locale_url(target_locale) - current_url1({:locale=>target_locale}) .sub "/"+I18n.locale.to_s+"/", "/"+target_locale.to_s+"/" - +# current_url1({:locale=>target_locale}) .sub "/"+I18n.locale.to_s+"/", "/"+target_locale.to_s+"/" + language_path(locale: target_locale) end def ffi1_icon (name) content_tag("i","", class: "ffi1-"+name )