Skip to content

Commit

Permalink
[rubygems/rubygems] Extract s.name to a variable
Browse files Browse the repository at this point in the history
  • Loading branch information
deivid-rodriguez authored and hsbt committed Aug 16, 2023
1 parent e92ace6 commit 4a3777b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/bundler/definition.rb
Expand Up @@ -810,6 +810,7 @@ def converge_specs(specs)
@specs_that_changed_sources = []

specs.each do |s|
name = s.name
dep = @dependencies.find {|d| s.satisfies?(d) }
lockfile_source = s.source

Expand Down Expand Up @@ -848,11 +849,11 @@ def converge_specs(specs)
else
# If the spec is no longer in the path source, unlock it. This
# commonly happens if the version changed in the gemspec
@unlock[:gems] << s.name
@unlock[:gems] << name
end
end

if dep.nil? && requested_dependencies.find {|d| s.name == d.name }
if dep.nil? && requested_dependencies.find {|d| name == d.name }
@unlock[:gems] << s.name
else
converged << s
Expand Down

0 comments on commit 4a3777b

Please sign in to comment.