Remove another unnecessary default argument
This commit is contained in:
parent
472a2cec1e
commit
af804f7475
@ -693,8 +693,8 @@ class Formula
|
||||
@skip_clean_paths ||= Set.new
|
||||
end
|
||||
|
||||
def keg_only reason, explanation=nil
|
||||
@keg_only_reason = KegOnlyReason.new(reason, explanation.to_s.chomp)
|
||||
def keg_only reason, explanation=""
|
||||
@keg_only_reason = KegOnlyReason.new(reason, explanation)
|
||||
end
|
||||
|
||||
# Flag for marking whether this formula needs C++ standard library
|
||||
|
@ -4,9 +4,7 @@ FormulaConflict = Struct.new(:name, :reason)
|
||||
# Used to annotate formulae that duplicate OS X provided software
|
||||
# or cause conflicts when linked in.
|
||||
class KegOnlyReason
|
||||
attr_reader :reason, :explanation
|
||||
|
||||
def initialize reason, explanation=nil
|
||||
def initialize(reason, explanation)
|
||||
@reason = reason
|
||||
@explanation = explanation
|
||||
end
|
||||
@ -38,9 +36,9 @@ class KegOnlyReason
|
||||
#{@explanation}
|
||||
EOS
|
||||
when :provided_until_xcode43
|
||||
"Xcode provides this software prior to version 4.3.\n\n#{explanation}"
|
||||
"Xcode provides this software prior to version 4.3.\n\n#{@explanation}"
|
||||
when :provided_until_xcode5
|
||||
"Xcode provides this software prior to version 5.\n\n#{explanation}"
|
||||
"Xcode provides this software prior to version 5.\n\n#{@explanation}"
|
||||
else
|
||||
@reason
|
||||
end.strip
|
||||
|
Loading…
x
Reference in New Issue
Block a user