Skip to content
Snippets Groups Projects
Unverified Commit 5ff41d05 authored by Jesus Federico's avatar Jesus Federico Committed by GitHub
Browse files

Allow multiple as host_url (#465)

parent 751aecf3
No related branches found
No related tags found
No related merge requests found
......@@ -65,8 +65,12 @@ module SessionsHelper
def parse_user_domain(hostname)
return hostname.split('.').first unless Rails.configuration.url_host
return '' unless hostname.include?(Rails.configuration.url_host)
hostname.chomp(Rails.configuration.url_host).chomp('.')
Rails.configuration.url_host.split(',').each do |url_host|
if hostname.include?(url_host)
return hostname.chomp(url_host).chomp('.')
end
end
''
end
def omniauth_options(env)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment