From 19f3b729fe75f4ac730618381c3254f556b4818f Mon Sep 17 00:00:00 2001 From: matiboy Date: Tue, 5 Nov 2013 12:03:22 +0800 Subject: [PATCH] Create collector on browser end if it does not exist --- lib/reporter.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/reporter.js b/lib/reporter.js index bbcd61f..bd6323d 100644 --- a/lib/reporter.js +++ b/lib/reporter.js @@ -75,7 +75,8 @@ var CoverageReporter = function(rootConfig, emitter, helper, logger) { var collector = collectors[browser.id]; if (!collector) { - return; + collectors[browser.id] = new istanbul.Collector(); + collector = collectors[browser.id]; } if (result && result.coverage) {