# File lib/openid/util.rb, line 249 def Util.normalize_url(url) url = url.strip unless url.starts_with?('http://') or url.starts_with?('https://') url = 'http://' + url end begin parsed = URI.parse(url) rescue URI::InvalidURIError return nil else return parsed.normalize.to_s end end