Skip to content
This repository has been archived by the owner on Apr 14, 2021. It is now read-only.

Commit

Permalink
switch reject to select
Browse files Browse the repository at this point in the history
Reject is clearly not the right method to use here, now I’m trying to
figure out what state of mind I was in when I wrote something that is
so obviously wrong.
  • Loading branch information
pducks32 committed Jul 1, 2015
1 parent 6243269 commit f0aa518
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions lib/bundler/installer/parallel_installer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,9 @@ def ignorable_dependency?(dep)

# Checks installed dependencies against spec's dependencies to make
# sure needed dependencies have been installed.
def dependencies_installed?(remaining_specs)
installed_specs = remaining_specs.reject(&:installed?).map(&:name)
already_installed = lambda {|dep| installed_specs.include? dep.name }
dependencies.all? {|d| already_installed[d] }
def dependencies_installed?(all_specs)
installed_specs = all_specs.select(&:installed?).map(&:spec)
dependencies.all? {|d| installed_specs.include? d }
end

# Represents only the non-development dependencies and the ones that
Expand Down

0 comments on commit f0aa518

Please sign in to comment.