fix(npm): resolve node_modules dir relative to package.json instead of cwd (#17885)

This commit is contained in:
David Sherret 2023-02-22 20:16:16 -05:00 committed by GitHub
parent a31d8869ea
commit ddc350780d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 219 additions and 141 deletions

View file

@ -463,7 +463,7 @@ impl ReplSession {
if !self.has_initialized_node_runtime {
deno_node::initialize_runtime(
&mut self.worker.js_runtime,
self.proc_state.options.node_modules_dir(),
self.proc_state.options.has_node_modules_dir(),
)
.await?;
self.has_initialized_node_runtime = true;