Merge pull request #4052 from reitermarkus/fix-cask-remote-search

Fix Cask search not showing remote matches.
This commit is contained in:
Markus Reiter 2018-04-12 00:21:46 +02:00 committed by GitHub
commit cd21ba904e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -30,6 +30,7 @@ module Hbc
opoo "Error searching on GitHub: #{error}\n" opoo "Error searching on GitHub: #{error}\n"
[] []
end end
matches.map do |match| matches.map do |match|
tap = Tap.fetch(match["repository"]["full_name"]) tap = Tap.fetch(match["repository"]["full_name"])
next if tap.installed? next if tap.installed?
@ -65,7 +66,7 @@ module Hbc
return return
end end
if !exact_match && partial_matches.empty? if !exact_match && partial_matches.empty? && remote_matches.empty?
puts "No Cask found for \"#{search_term}\"." puts "No Cask found for \"#{search_term}\"."
return return
end end