From 3d9d2e4bf8a287f7adabed774034ea56e58a46ab Mon Sep 17 00:00:00 2001 From: alexlamsl Date: Sat, 6 Feb 2016 03:32:26 +0800 Subject: [PATCH] fix cli error reporting it was attempting to write the error object onto stderr, which errs out by itself and masked the original error and stack trace --- cli.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cli.js b/cli.js index a2dd2cc..b4d146d 100755 --- a/cli.js +++ b/cli.js @@ -168,7 +168,7 @@ cli.main(function(args, options) { catch (e) { status = 3; cli.error('Minification error'); - process.stderr.write(e); + process.stderr.write((e.stack || e).toString()); } if (minifyOptions.lint) { -- 2.34.1