lib/bundler/lazy_specification.rb in bundler-2.3.16 vs lib/bundler/lazy_specification.rb in bundler-2.3.17

- old
+ new

@@ -82,11 +82,11 @@ search_object = if source.is_a?(Source::Path) Dependency.new(name, version) else ruby_platform_materializes_to_ruby_platform? ? self : Dependency.new(name, version) end - platform_object = Gem::Platform.new(platform) + platform_object = ruby_platform_materializes_to_ruby_platform? ? Gem::Platform.new(platform) : Gem::Platform.local candidates = source.specs.search(search_object) same_platform_candidates = candidates.select do |spec| MatchPlatform.platforms_match?(spec.platform, platform_object) end installable_candidates = same_platform_candidates.select do |spec| @@ -150,9 +150,9 @@ # only included non-ruby platforms), but we're also keeping this behaviour # on newer bundlers unless users generate the lockfile from scratch or # explicitly add a more specific platform. # def ruby_platform_materializes_to_ruby_platform? - !Bundler.most_specific_locked_platform?(Gem::Platform::RUBY) || Bundler.settings[:force_ruby_platform] + !Bundler.most_specific_locked_platform?(generic_local_platform) || Bundler.settings[:force_ruby_platform] end end end