Skip to content

Commit

Permalink
Use LazySets for ContextModuleFactory
Browse files Browse the repository at this point in the history
  • Loading branch information
sokra committed Apr 23, 2021
1 parent acfea9d commit 88d90be
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions lib/ContextModuleFactory.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const { AsyncSeriesWaterfallHook, SyncWaterfallHook } = require("tapable");
const ContextModule = require("./ContextModule");
const ModuleFactory = require("./ModuleFactory");
const ContextElementDependency = require("./dependencies/ContextElementDependency");
const LazySet = require("./util/LazySet");
const { cachedSetProperty } = require("./util/cleverMerge");
const { createFakeHook } = require("./util/deprecation");
const { join } = require("./util/fs");
Expand Down Expand Up @@ -87,9 +88,9 @@ module.exports = class ContextModuleFactory extends ModuleFactory {
const dependencies = data.dependencies;
const resolveOptions = data.resolveOptions;
const dependency = /** @type {ContextDependency} */ (dependencies[0]);
const fileDependencies = new Set();
const missingDependencies = new Set();
const contextDependencies = new Set();
const fileDependencies = new LazySet();
const missingDependencies = new LazySet();
const contextDependencies = new LazySet();
this.hooks.beforeResolve.callAsync(
{
context: context,
Expand Down

0 comments on commit 88d90be

Please sign in to comment.