Skip to content

Commit

Permalink
Update get-entry-name.js
Browse files Browse the repository at this point in the history
  • Loading branch information
mater1996 authored Dec 11, 2023
1 parent 3de3c59 commit 821b55c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/webpack-plugin/lib/utils/get-entry-name.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module.exports = function (loaderContext) {
const moduleGraph = loaderContext._compilation.moduleGraph
let entryName = ''
for (const [name, { dependencies }] of loaderContext._compilation.entries) {
for(const dep of dependencies) {
for (const dep of dependencies) {
const entryModule = moduleGraph.getModule(dep)
if (entryModule && entryModule.resource === loaderContext.resource) {
entryName = name
Expand Down

0 comments on commit 821b55c

Please sign in to comment.