Skip to content

Commit

Permalink
Merge pull request #92 from dabing1022/fix_multiple_dependencies
Browse files Browse the repository at this point in the history
fix: multiple dependencies error
  • Loading branch information
su350380433 authored Jan 14, 2021
2 parents 0703b77 + ac03d79 commit 07faa4a
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions cocoapods-imy-bin/lib/cocoapods-imy-bin/command/bin/update.rb
Original file line number Diff line number Diff line change
Expand Up @@ -111,9 +111,12 @@ def self.load_local_podfile
end

target_dependencies.each do |target_dependency|
next unless target_dependency.is_a?(Hash) &&
target_dependency.keys.first &&
target_dependency.keys.first == local_dependency.keys.first
dp_hash_equal = target_dependency.is_a?(Hash) &&
target_dependency.keys.first &&
target_dependency.keys.first == local_dependency.keys.first
dp_str_equal = target_dependency.is_a?(String) &&
target_dependency == local_dependency.keys.first
next unless dp_hash_equal || dp_str_equal

target_dependencies.delete target_dependency
break
Expand Down

0 comments on commit 07faa4a

Please sign in to comment.