refactor: no modules for linked

This commit is contained in:
cha0s 2024-01-27 04:13:25 -06:00
parent df40891a0b
commit 47ba15834a

View File

@ -45,8 +45,8 @@ module.exports = async function explicate(
realResolvedCandidate = realResolvedCandidate.slice(0, -5);
}
}
// Aliased or symlinked? Include submodules.
if (path !== request || isSymlink) {
// Aliased? Include submodules.
if (path !== request) {
const submodules = join(realResolvedCandidate, 'node_modules');
resolver.addModules(submodules);
// Runtime NODE_PATH hacking.