diff options
author | Homu <homu@barosl.com> | 2015-11-27 15:12:00 +0900 |
---|---|---|
committer | Homu <homu@barosl.com> | 2015-11-27 15:12:00 +0900 |
commit | 437f604956e629e1b96270d87f6fdb05b189de2d (patch) | |
tree | e01f1583c45652499610c07a95a28a5b869980f1 /lib/bundler/fetcher.rb | |
parent | 50731b93d77fc8b4155d11306afb51d5e9534060 (diff) | |
parent | 046f2831c1518519c47b8b5be97c1ed8aef4e58c (diff) | |
download | bundler-437f604956e629e1b96270d87f6fdb05b189de2d.tar.gz |
Auto merge of #4124 - bundler:seg-rubocop, r=indirect
More rubocop_todo cleanup
Diffstat (limited to 'lib/bundler/fetcher.rb')
-rw-r--r-- | lib/bundler/fetcher.rb | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/lib/bundler/fetcher.rb b/lib/bundler/fetcher.rb index 4ebbe7ac..4b79a7d8 100644 --- a/lib/bundler/fetcher.rb +++ b/lib/bundler/fetcher.rb @@ -4,7 +4,6 @@ require "securerandom" require "zlib" module Bundler - # Handles all the fetching with the rubygems server class Fetcher autoload :Downloader, "bundler/fetcher/downloader" @@ -106,9 +105,7 @@ module Bundler specs = {} fetchers.dup.each do |f| - unless f.api_fetcher? && !gem_names - break if specs = f.specs(gem_names) - end + break unless f.api_fetcher? && !gem_names || !specs = f.specs(gem_names) fetchers.delete(f) end @use_api = false if fetchers.none?(&:api_fetcher?) @@ -157,7 +154,11 @@ module Bundler if ruby.engine != "ruby" # engine_version raises on unknown engines - engine_version = ruby.engine_version rescue "???" + engine_version = begin + ruby.engine_version + rescue + "???" + end agent << " #{ruby.engine}/#{engine_version}" end @@ -183,8 +184,6 @@ module Bundler def http_proxy if uri = connection.proxy_uri uri.to_s - else - nil end end |