summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Giddins <segiddins@segiddins.me>2017-02-15 17:47:46 -0600
committerSamuel Giddins <segiddins@segiddins.me>2017-02-15 17:47:46 -0600
commitfe0fdb108b9a72889383b99d98dd8e58ae75a557 (patch)
tree64b0c4177d286d8e023385d01ee1d10bc33e8815
parentf3e44c1cdce8c6baad67af6323a9fd44c5f42411 (diff)
downloadbundler-seg-api-missing-dependencies.tar.gz
[LazySpecification] Handle when the search in __materialize__ returns nilseg-api-missing-dependencies
-rw-r--r--lib/bundler/lazy_specification.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/bundler/lazy_specification.rb b/lib/bundler/lazy_specification.rb
index b7dddcbf35..91ccab2e87 100644
--- a/lib/bundler/lazy_specification.rb
+++ b/lib/bundler/lazy_specification.rb
@@ -74,7 +74,7 @@ module Bundler
source.gemspec.tap {|s| s.source = source }
else
search = source.specs.search(search_object).last
- if search.platform != platform && !search.runtime_dependencies.-(dependencies.reject {|d| d.type == :development }).empty?
+ if search && search.platform != platform && !search.runtime_dependencies.-(dependencies.reject {|d| d.type == :development }).empty?
Bundler.ui.warn "Unable to use the platform-specific (#{search.platform}) version of #{name} (#{version}) " \
"because it has different dependencies from the #{platform} version. " \
"To use the platform-specific version of the gem, run `bundle config specific_platform true` and install again."