fix: #7351, display less errors with location and error message

v1.18.x
Barış Soner Uşaklı 5 years ago
parent 609e37a67b
commit d1cb405d86

@ -218,7 +218,7 @@ exports.build = function (targets, options, callback) {
},
], function (err) {
if (err) {
winston.error('[build] Encountered error during build step\n' + err.stack ? err.stack : err);
winston.error('[build] Encountered error during build step\n' + (err.stack ? err.stack : err));
return callback(err);
}

@ -271,7 +271,8 @@ function buildCSS(data, callback) {
javascriptEnabled: true,
}, function (err, lessOutput) {
if (err) {
return callback(err);
// display less parser errors properly
return callback(new Error(String(err)));
}
postcss(data.minify ? [

Loading…
Cancel
Save