Make Formula#installed_alias_target_changed? clearer

This commit is contained in:
Alyssa Ross 2016-09-18 19:43:54 +01:00
parent 8bae49941c
commit 49bfb3fb4a

View File

@ -1164,7 +1164,8 @@ class Formula
# Has the target of the alias used to install this formula changed?
# Returns false if the formula wasn't installed with an alias.
def installed_alias_target_changed?
![self, nil].include?(current_installed_alias_target)
target = current_installed_alias_target
target && target != self
end
# Is this formula the target of an alias used to install an old formula?