From ee5193e3e855d4473258c17ccc49ab1fd37d357b Mon Sep 17 00:00:00 2001 From: Adam Vandenberg Date: Sun, 4 Mar 2012 17:34:29 -0800 Subject: [PATCH] invert condition --- Library/Homebrew/formula.rb | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb index 44cf0d3b81..151aeb2b60 100644 --- a/Library/Homebrew/formula.rb +++ b/Library/Homebrew/formula.rb @@ -629,10 +629,9 @@ private end def set_instance_variable(type) - unless instance_variable_defined? "@#{type}" - class_value = self.class.send(type) - instance_variable_set("@#{type}", class_value) if class_value - end + return if instance_variable_defined? "@#{type}" + class_value = self.class.send(type) + instance_variable_set("@#{type}", class_value) if class_value end def method_added method