mirror of
https://github.com/internetee/registry.git
synced 2025-07-27 21:16:12 +02:00
Added error messages translations to white ips
This commit is contained in:
parent
289159bff2
commit
97c11f5dfd
7 changed files with 161 additions and 50 deletions
|
@ -5,6 +5,7 @@ module Repp
|
|||
|
||||
around_action :log_request
|
||||
before_action :authenticate_user
|
||||
before_action :set_locale
|
||||
before_action :validate_webclient_ca
|
||||
before_action :validate_client_certs
|
||||
before_action :check_ip_restriction
|
||||
|
@ -176,6 +177,10 @@ module Repp
|
|||
authorize!(:throttled_user, @domain) unless current_user || action_name == 'tara_callback'
|
||||
current_user
|
||||
end
|
||||
|
||||
def set_locale
|
||||
I18n.locale = current_user&.try(:locale) || params[:locale] || I18n.default_locale
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue