Files
ThreadNet-Web/patches/app-builder-lib.patch
T

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

34 lines
1.6 KiB
Diff
Raw Normal View History

2026-03-24 16:51:03 +00:00
diff --git a/out/node-module-collector/moduleManager.js b/out/node-module-collector/moduleManager.js
index e9d6d16f8950c01417039d65ed1939009d642b7a..9f47c5e18fb34fe60e4f09bf512f9639aa2d90c0 100644
2026-03-24 16:51:03 +00:00
--- a/out/node-module-collector/moduleManager.js
+++ b/out/node-module-collector/moduleManager.js
2026-03-24 17:20:59 +00:00
@@ -5,6 +5,7 @@ const builder_util_1 = require("builder-util");
const fs = require("fs-extra");
const path = require("path");
const semver = require("semver");
+const searchModule = require("../electron/search-module");
var LogMessageByKey;
(function (LogMessageByKey) {
LogMessageByKey["PKG_DUPLICATE_REF"] = "duplicate dependency references";
@@ -115,15 +116,15 @@ class ModuleManager {
2026-03-24 16:51:03 +00:00
return { packageDir: path.dirname(direct), packageJson: json };
}
}
- // 2) upward hoisted search, then 3) downward non-hoisted search
2026-03-24 17:20:59 +00:00
+ // 2) upward hoisted search, then 3) downward non-hoisted search, then 4) downward from workspace root
const upward = await this.upwardSearch(parentDir, pkgName, requiredRange);
if (upward) {
return upward;
}
- if (skipDownwardSearch) {
- return null;
- }
- return (await this.downwardSearch(parentDir, pkgName, requiredRange)) || null;
2026-03-24 17:20:59 +00:00
+ const workspaceRoot = await searchModule.getProjectRootPath(parentDir);
+ return (await this.downwardSearch(parentDir, pkgName, requiredRange)) ||
2026-03-24 17:20:59 +00:00
+ (await this.downwardSearch(workspaceRoot, pkgName, requiredRange)) ||
+ null;
2026-03-24 16:51:03 +00:00
}
semverSatisfies(found, range) {
if ((0, builder_util_1.isEmptyOrSpaces)(range) || range === "*") {