lib/utopia/localization.rb
# A wrapper to provide easy access to locale related data in the request.
A wrapper to provide easy access to locale related data in the request.
A wrapper to provide easy access to locale related data in the request .
def host_preferred_locales(env)
			http_host = env[Rack::HTTP_HOST]
			@hosts.each do |pattern, locale|
				yield locale if http_host[pattern]
			end
		end
def host_preferred_locales ( env ) http_host = env [ Rack :: HTTP_HOST ] @hosts . each do | pattern , locale | yield locale if http_host [ pattern ] end end
A wrapper to provide easy access to locale related data in the request.
A wrapper to provide easy access to locale related data in the request .
# Yield all hosts which match the incoming http_host:
env