forked from External/greenlight
GRN2-112: Default language fallback fails with a 500 error (#469)
* GRN2-112: Default language fallback fails with a 500 error * Updates for passing rspec tests * Added cache for gitlab ci * Updated cache for gitlab * Restored Dockerfile * Fixed glitch in filter for build and deployment
This commit is contained in:
@ -44,11 +44,12 @@ class ApplicationController < ActionController::Base
|
||||
end
|
||||
|
||||
def update_locale(user)
|
||||
I18n.locale = if user && user.language != 'default'
|
||||
user.language.tr('-', '_')
|
||||
locale = if user && user.language != 'default'
|
||||
user.language
|
||||
else
|
||||
http_accept_language.language_region_compatible_from(I18n.available_locales)
|
||||
end
|
||||
I18n.locale = locale.tr('-', '_') unless locale.nil?
|
||||
end
|
||||
|
||||
def meeting_name_limit
|
||||
|
Reference in New Issue
Block a user