mirror of
https://github.com/nodejs/node.git
synced 2025-08-15 13:48:44 +02:00
lib, tools: remove duplicate requires
PR-URL: https://github.com/nodejs/node/pull/54987 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
This commit is contained in:
parent
c6d20a034d
commit
5c22d19f44
12 changed files with 20 additions and 43 deletions
|
@ -34,6 +34,7 @@ const { kEmptyObject } = require('internal/util');
|
|||
const {
|
||||
compileSourceTextModule,
|
||||
getDefaultConditions,
|
||||
forceDefaultLoader,
|
||||
} = require('internal/modules/esm/utils');
|
||||
const { kImplicitTypeAttribute } = require('internal/modules/esm/assert');
|
||||
const { ModuleWrap, kEvaluating, kEvaluated } = internalBinding('module_wrap');
|
||||
|
@ -798,7 +799,7 @@ function createModuleLoader() {
|
|||
// Don't spawn a new worker if custom loaders are disabled. For instance, if
|
||||
// we're already in a worker thread created by instantiating
|
||||
// CustomizedModuleLoader; doing so would cause an infinite loop.
|
||||
if (!require('internal/modules/esm/utils').forceDefaultLoader()) {
|
||||
if (!forceDefaultLoader()) {
|
||||
const userLoaderPaths = getOptionValue('--experimental-loader');
|
||||
if (userLoaderPaths.length > 0) {
|
||||
if (!emittedLoaderFlagWarning) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue