8000 Fix an infinite recursion issue by only checking loc async chunks in… · rbuckton/rushstack@b365b1f · GitHub
[go: up one dir, main page]

Skip to content

Commit b365b1f

Browse files
committed
Fix an infinite recursion issue by only checking loc async chunks in runtime chunks.
1 parent 0186908 commit b365b1f

File tree

1 file changed
+2
-1
lines changed

1 file changed

+2
-1
lines changed

webpack/localization-plugin/src/LocalizationPlugin.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -646,7 +646,8 @@ export class LocalizationPlugin implements Webpack.Plugin {
646646
}
647647
}
648648

649-
if (!chunkHasAnyLocModules) {
649+
// Check async chunks if this is a runtime chunk and we haven't directly found any localized modules
650+
if (chunk.hasRuntime() && !chunkHasAnyLocModules) {
650651
for (const asyncChunk of chunk.getAllAsyncChunks()) {
651652
if (this._chunkHasLocalizedModules(asyncChunk)) {
652653
chunkHasAnyLocModules = true;

0 commit comments

Comments
 (0)
0