fix(install): correct check_dir tautology and add --workspace web test

- check_dir = npm_dir if audit_extra else npm_dir evaluated identically in
  both branches; change to PROJECT_ROOT if audit_extra else npm_dir so
  workspace-scoped audits check the workspace root's node_modules
- Add test_npm_install_uses_workspace_web_scope asserting --workspace web is
  passed adjacently in the _build_web_ui npm install invocation
This commit is contained in:
Zak B. Elep
2026-06-06 18:22:20 -07:00
committed by Teknium
parent 4bf52022e5
commit 675fb10240
2 changed files with 14 additions and 1 deletions
+1 -1
View File
@@ -1469,7 +1469,7 @@ def run_doctor(args):
# For workspace-scoped audits run from PROJECT_ROOT the
# node_modules check must use the workspace root; standalone dirs
# (whatsapp-bridge) check their own node_modules.
check_dir = npm_dir if audit_extra else npm_dir
check_dir = PROJECT_ROOT if audit_extra else npm_dir
if not (check_dir / "node_modules").exists():
continue
try: