From fc5fd6ce7138b947f42e810119eefdace6c79f73 Mon Sep 17 00:00:00 2001 From: Florent Cailhol Date: Fri, 2 Mar 2018 09:39:16 +0100 Subject: [PATCH] Remove Tapable#apply calls --- bin/process-options.js | 8 +++----- bin/webpack.js | 8 +++----- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/bin/process-options.js b/bin/process-options.js index 0b938f1669e..3c3f8e2705c 100644 --- a/bin/process-options.js +++ b/bin/process-options.js @@ -153,11 +153,9 @@ module.exports = function processOptions(yargs, argv) { if (argv.progress) { const ProgressPlugin = require("webpack").ProgressPlugin; - compiler.apply( - new ProgressPlugin({ - profile: argv.profile - }) - ); + new ProgressPlugin({ + profile: argv.profile + }).apply(compiler); } function compilerCallback(err, stats) { diff --git a/bin/webpack.js b/bin/webpack.js index e61c67d1a6b..7bebb6abab9 100755 --- a/bin/webpack.js +++ b/bin/webpack.js @@ -441,11 +441,9 @@ if (argv.progress) { const ProgressPlugin = require("webpack").ProgressPlugin; - compiler.apply( - new ProgressPlugin({ - profile: argv.profile - }) - ); + new ProgressPlugin({ + profile: argv.profile + }).apply(compiler); } if (outputOptions.infoVerbosity === "verbose") {