mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00
Suggestion by @MikeMcQuaid
"ActiveSupport adds blank? to NilClass."
This commit is contained in:
parent
bfbea8be26
commit
4063675e0e
@ -50,7 +50,8 @@ module Homebrew
|
|||||||
end
|
end
|
||||||
|
|
||||||
def write_formula!
|
def write_formula!
|
||||||
raise "name should not be empty" if @name.to_s == ""
|
raise ArgumentError, "name is blank!" if @name.blank?
|
||||||
|
raise ArgumentError, "tap is blank!" if @tap.blank?
|
||||||
|
|
||||||
path = @tap.new_formula_path(@name)
|
path = @tap.new_formula_path(@name)
|
||||||
raise "#{path} already exists" if path.exist?
|
raise "#{path} already exists" if path.exist?
|
||||||
|
Loading…
x
Reference in New Issue
Block a user