Skip to content

Commit

Permalink
If the .metadata directory has versions, a cask is considered insta…
Browse files Browse the repository at this point in the history
…lled. (Homebrew#23328)
  • Loading branch information
reitermarkus authored and Jonathan Dahan committed Sep 24, 2016
1 parent 0a4cb19 commit b78f6f7
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions lib/hbc/cask.rb
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,7 @@ def versions
end

def installed?
return false unless caskroom_path.exist?

if metadata_master_container_path.exist?
!(metadata_master_container_path.children.map(&:basename) &
caskroom_path.children.map(&:basename)).empty?
else
!caskroom_path.children.empty?
end
!versions.empty?
end

def to_s
Expand Down

0 comments on commit b78f6f7

Please sign in to comment.