Permalink
Browse files

Fix undefined method `empty?' for nil:NilClass error

  • Loading branch information...
1 parent 18b741e commit 8d27fff74dc24745bbaf2a514719440bf54f4b00 @bronson bronson committed Jul 14, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/guard/dsl.rb
View
@@ -9,7 +9,7 @@ def evaluate_guardfile(options = {})
@@options = options.dup
instance_eval_guardfile(fetch_guardfile_contents)
- UI.error "No guards found in Guardfile, please add at least one." if ::Guard.guards.empty?
+ UI.error "No guards found in Guardfile, please add at least one." if ::Guard.guards.nil? || ::Guard.guards.empty?
end
def revaluate_guardfile

0 comments on commit 8d27fff

Please sign in to comment.