From 222ffa74d88d9a923bc02bddf926594b38f06e8e Mon Sep 17 00:00:00 2001 From: Glen Selle Date: Wed, 11 Sep 2019 13:09:37 -0500 Subject: [PATCH] Log original error for easier debugging of the underlying build error --- lib/install.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/install.js b/lib/install.js index cf981de..b1fd678 100644 --- a/lib/install.js +++ b/lib/install.js @@ -20,7 +20,7 @@ bin.run(['--version']).then(() => { ]).then(() => { log.success('pngquant built successfully'); }).catch(err => { - err.message = `pngquant failed to build, make sure that ${libpng} is installed`; + log.error(`pngquant failed to build -- usually this happens because ${libpng} is not installed`); log.error(err.stack); // eslint-disable-next-line unicorn/no-process-exit