lib/bundler/mirror.rb in bundler-1.13.0.rc.1 vs lib/bundler/mirror.rb in bundler-1.13.0.rc.2

- old
+ new

@@ -41,11 +41,11 @@ end private def fetch_valid_mirror_for(uri) - mirror = (@mirrors[URI(uri.to_s.downcase)] || Mirror.new(uri)).validate!(@prober) + mirror = (@mirrors[URI(uri.to_s.downcase)] || @mirrors[URI(uri.to_s).host] || Mirror.new(uri)).validate!(@prober) mirror = Mirror.new(uri) unless mirror.valid? mirror end end @@ -119,10 +119,10 @@ @fallback = !fallback.nil? @all = false if uri == "all" @all = true else - @uri = Settings.normalize_uri(uri) + @uri = URI(uri).absolute? ? Settings.normalize_uri(uri) : uri end @value = value end def all?