diff options
author | David RodrÃguez <deivid.rodriguez@riseup.net> | 2019-03-08 13:48:17 +0100 |
---|---|---|
committer | David RodrÃguez <deivid.rodriguez@riseup.net> | 2019-03-08 13:48:17 +0100 |
commit | 631bff3c8ab197027801cb3d602fa92b2c5e2512 (patch) | |
tree | 5263b1e0f38ce7eca748c2072f9eb63de4785d6f | |
parent | ed85fb9f7acc20c317737f3e157bcee38fbd527c (diff) | |
download | bundler-631bff3c8ab197027801cb3d602fa92b2c5e2512.tar.gz |
Fix rubocop issues
-rw-r--r-- | lib/bundler/fetcher/compact_index.rb | 12 | ||||
-rw-r--r-- | spec/support/artifice/compact_index_rate_limited.rb | 4 |
2 files changed, 8 insertions, 8 deletions
diff --git a/lib/bundler/fetcher/compact_index.rb b/lib/bundler/fetcher/compact_index.rb index d462aa1463..a117af72fa 100644 --- a/lib/bundler/fetcher/compact_index.rb +++ b/lib/bundler/fetcher/compact_index.rb @@ -40,12 +40,12 @@ module Bundler log_specs "Looking up gems #{remaining_gems.inspect}" deps = begin - parallel_compact_index_client.dependencies(remaining_gems) - rescue TooManyRequestsError - @bundle_worker.stop if @bundle_worker - @bundle_worker = nil # reset it. Not sure if necessary - serial_compact_index_client.dependencies(remaining_gems) - end + parallel_compact_index_client.dependencies(remaining_gems) + rescue TooManyRequestsError + @bundle_worker.stop if @bundle_worker + @bundle_worker = nil # reset it. Not sure if necessary + serial_compact_index_client.dependencies(remaining_gems) + end next_gems = deps.map {|d| d[3].map(&:first).flatten(1) }.flatten(1).uniq deps.each {|dep| gem_info << dep } complete_gems.concat(deps.map(&:first)).uniq! diff --git a/spec/support/artifice/compact_index_rate_limited.rb b/spec/support/artifice/compact_index_rate_limited.rb index 5f22e98e2e..d8f4fc941c 100644 --- a/spec/support/artifice/compact_index_rate_limited.rb +++ b/spec/support/artifice/compact_index_rate_limited.rb @@ -6,7 +6,7 @@ Artifice.deactivate class CompactIndexRateLimited < CompactIndexAPI class RequestCounter - def self.init + def self.queue @queue ||= Queue.new end @@ -24,7 +24,7 @@ class CompactIndexRateLimited < CompactIndexAPI end configure do - RequestCounter.init + RequestCounter.queue end get "/info/:name" do |