From c8887ac6c3e4c88df6cc41df1343fd3a4a68196a Mon Sep 17 00:00:00 2001 From: Craig Vermeer Date: Thu, 10 Mar 2016 13:40:39 -0500 Subject: [PATCH] fix: check if outputFile is set before checking for absolute outputFile paths Before checking to see if the outputFile is an absolute path, first make sure that outputFile is set. Fixes #87 --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index bd65d7e..dba8009 100644 --- a/index.js +++ b/index.js @@ -58,7 +58,7 @@ var JUnitReporter = function (baseReporterDecorator, config, logger, helper, for var writeXmlForBrowser = function (browser) { var safeBrowserName = browser.name.replace(/ /g, '_') var newOutputFile - if (pathIsAbsolute(outputFile)) { + if (outputFile && pathIsAbsolute(outputFile)) { newOutputFile = outputFile } else if (outputFile != null) { var dir = useBrowserName ? path.join(outputDir, safeBrowserName)