mirror of https://github.com/webpack/webpack.git
Merge pull request #4620 from zinserjan/fix-progress-plugin
Fix ProgressPlugin for multi compiler caused by ES6 refactoring
This commit is contained in:
commit
bb7d53c083
|
|
@ -23,7 +23,7 @@ class ProgressPlugin {
|
|||
if(compiler.compilers) {
|
||||
const states = new Array(compiler.compilers.length);
|
||||
compiler.compilers.forEach(function(compiler, idx) {
|
||||
compiler.apply(new ProgressPlugin((p, msg) => {
|
||||
compiler.apply(new ProgressPlugin(function(p, msg) {
|
||||
states[idx] = Array.prototype.slice.apply(arguments);
|
||||
handler.apply(null, [
|
||||
states.map(state => state && state[0] || 0).reduce((a, b) => a + b) / states.length,
|
||||
|
|
|
|||
Loading…
Reference in New Issue