Skip to content

Commit

Permalink
Fix Collapsed Output
Browse files Browse the repository at this point in the history
Fix collapsed output to write to the stream passed rather than always
writing to stdout.

Call passed callback when done.
  • Loading branch information
cwarden authored and Dave Pacheco committed Aug 28, 2015
1 parent b129a8b commit f9f5af8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/output-collapsed.js
Expand Up @@ -22,6 +22,7 @@ exports.emit = function emitCollapsed(args, callback)
'required "output" argument must be a function');

args.stacks.eachStackByCount(function (frames, count) {
process.stdout.write(frames.join(',') + ' ' + count + '\n');
args.output.write(frames.join(',') + ' ' + count + '\n');
});
callback();
};

0 comments on commit f9f5af8

Please sign in to comment.