Skip to content

Commit

Permalink
[rubygems/rubygems] No need to redownload if package already there
Browse files Browse the repository at this point in the history
  • Loading branch information
deivid-rodriguez authored and matzbot committed Jun 11, 2022
1 parent a9077af commit 3f69774
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/bundler/source/rubygems.rb
Expand Up @@ -462,6 +462,7 @@ def fetch_gem(spec, previous_spec = nil)

cache_path = download_cache_path(spec) || default_cache_path_for(rubygems_dir)
gem_path = "#{cache_path}/#{spec.file_name}"
return gem_path if File.exist?(gem_path)

if requires_sudo?
download_path = Bundler.tmp(spec.full_name)
Expand Down

0 comments on commit 3f69774

Please sign in to comment.