diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 4a87bd1..656b416 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -24,6 +24,9 @@ class ApplicationController < ActionController::Base def set_locale I18n.locale = params[:locale] || I18n.default_locale + if user_signed_in? and current_user.language != I18n.locale + current_user.update(language: I18n.locale) + end end def set_view_paths