1 parent 4d186ee commit 9df9232Copy full SHA for 9df9232
1 file changed
lib/FlagDependencyExportsPlugin.js
@@ -47,15 +47,16 @@ class FlagDependencyExportsPlugin {
47
const depIdent = dep.identifier();
48
// if this was not yet initialized
49
// initialize it as an array containing the module and stop
50
- if(!dependencies[depIdent]) {
+ const array = dependencies[depIdent];
51
+ if(!array) {
52
dependencies[depIdent] = [module];
53
return;
54
}
55
56
// check if this module is known
57
// if not, add it to the dependencies for this identifier
- if(dependencies[depIdent].indexOf(module) < 0)
58
- dependencies[depIdent].push(module);
+ if(array.indexOf(module) < 0)
59
+ array.push(module);
60
});
61
62
let changed = false;
0 commit comments