`nvm_check_global_modules` ran `npm --version` and `npm list -g` in `$PWD`, so the project `.npmrc` applied, eg its `logs-dir` on npm v8.11 through v10.5. The "npm unavailable" test put its fake npm on a relative `PATH` entry, which no longer resolves from `/`.