From d18ccc168fe143dcb010d3ef95c97ee62632ee45 Mon Sep 17 00:00:00 2001 From: Kevin Sawicki Date: Thu, 30 May 2013 15:24:21 -0700 Subject: [PATCH] Guard against null options --- Gruntfile.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gruntfile.coffee b/Gruntfile.coffee index 96815f283..f38bfc084 100644 --- a/Gruntfile.coffee +++ b/Gruntfile.coffee @@ -25,7 +25,7 @@ module.exports = (grunt) -> stderrChunks = [] spawned.stderr.on 'data', (data) -> stderrChunks.push(data) spawned.on 'close', (code) -> - if code is 0 or options.ignoreFailures + if code is 0 or options?.ignoreFailures callback(null, Buffer.concat(stdoutChunks).toString()) else if stderrChunks.length > 0 error = Buffer.concat(stderrChunks).toString()