Skip to content

Commit

Permalink
Suppress logging when --tasks-json flag is specified
Browse files Browse the repository at this point in the history
  • Loading branch information
sttk authored and phated committed Mar 13, 2019
1 parent be9d25a commit e9f1863
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion lib/shared/log/to-console.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ function toConsole(log, opts) {

// Return immediately if logging is
// not desired.
if (opts.tasksSimple || opts.silent) {
if (opts.tasksSimple || opts.tasksJson || opts.silent) {
// Keep from crashing process when silent.
log.on('error', noop);
return;
Expand Down
1 change: 0 additions & 1 deletion test/flags-tasks-json.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ describe('flag: --tasks-json', function() {
function cb(err, stdout, stderr) {
expect(err).toEqual(null);
expect(stderr).toEqual('');
stdout = skipLines(stdout, 1);
expect(JSON.parse(stdout)).toEqual(expected);
done(err);
}
Expand Down

0 comments on commit e9f1863

Please sign in to comment.