MCPcopy
hub / github.com/webpack/webpack / finishUpdateParent

Method finishUpdateParent

lib/ModuleGraph.js:363–377  ·  view source on GitHub ↗

* Finish update parent. * @returns {void}

()

Source from the content-addressed store, hash-verified

361 * @returns {void}
362 */
363 finishUpdateParent() {
364 if (this._modulesNeedingSort.size === 0) {
365 return;
366 }
367 for (const mod of this._modulesNeedingSort) {
368 // If dependencies like HarmonyImportSideEffectDependency and HarmonyImportSpecifierDependency have a SourceOrder,
369 // we sort based on it; otherwise, we preserve the original order.
370 sortWithSourceOrder(
371 mod.dependencies,
372 this._dependencySourceOrderMap,
373 (dep, index) => this.setParentDependenciesBlockIndex(dep, index)
374 );
375 }
376 this._modulesNeedingSort.clear();
377 }
378
379 /**
380 * Removes connection.

Callers 1

applyMethod · 0.80

Calls 3

sortWithSourceOrderFunction · 0.85
clearMethod · 0.45

Tested by

no test coverage detected