Corrected run_on defaulting line to work correctly if a symbol is passed in
This commit is contained in:
parent
13287fb59b
commit
96ba8c7b31
@ -38,7 +38,7 @@ module Guard
|
|||||||
|
|
||||||
def run_for? command
|
def run_for? command
|
||||||
run_on = @options[:run_on]
|
run_on = @options[:run_on]
|
||||||
run_on = [:start, :change] if not run_on or run_on.empty?
|
run_on = [:start, :change] if not run_on or run_on.to_s.empty?
|
||||||
run_on = [run_on] unless run_on.respond_to?(:include?)
|
run_on = [run_on] unless run_on.respond_to?(:include?)
|
||||||
run_on.include?(command)
|
run_on.include?(command)
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user