do not swallow errors
This commit is contained in:
parent
a8bd05298e
commit
1f8c3af5f9
@ -166,9 +166,14 @@ gulp.task("dist-prod", ["compile-prod"], function () {
|
|||||||
gulp.task("compile-prod", function (callback) {
|
gulp.task("compile-prod", function (callback) {
|
||||||
let config = require("./webpack.config.js")({prod: true});
|
let config = require("./webpack.config.js")({prod: true});
|
||||||
webpack(config, function(err, stats) {
|
webpack(config, function(err, stats) {
|
||||||
if(err) {
|
if (err) {
|
||||||
throw new gutil.PluginError("webpack", err);
|
throw new gutil.PluginError("webpack", err);
|
||||||
}
|
}
|
||||||
|
if (stats.hasErrors() || stats.hasWarnins) {
|
||||||
|
gutil.log("[webpack]", stats.toString({
|
||||||
|
colors: true,
|
||||||
|
}));
|
||||||
|
}
|
||||||
callback();
|
callback();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user