Skip to content

Commit

Permalink
fix: improve check for custom webpack-dev-server package existance
Browse files Browse the repository at this point in the history
  • Loading branch information
snitin315 committed May 6, 2023
1 parent 10165f8 commit 192c119
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/webpack-cli/src/webpack-cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,10 @@ class WebpackCLI implements IWebpackCLI {
}

// Allow to use `./path/to/webpack-dev-server.js` outside `node_modules`
if (dependency === WEBPACK_DEV_SERVER_PACKAGE && fs.existsSync(WEBPACK_PACKAGE)) {
if (
dependency === WEBPACK_DEV_SERVER_PACKAGE &&
fs.existsSync(WEBPACK_DEV_SERVER_PACKAGE)

Check warning on line 531 in packages/webpack-cli/src/webpack-cli.ts

View check run for this annotation

Codecov / codecov/patch

packages/webpack-cli/src/webpack-cli.ts#L531

Added line #L531 was not covered by tests
) {
skipInstallation = true;
}

Expand Down

0 comments on commit 192c119

Please sign in to comment.