1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-22 07:14:47 -05:00

perf: remove duplicate env::current_dir call in package.json search (#22255)

Micro-optimization.
This commit is contained in:
David Sherret 2024-02-04 00:11:12 -05:00 committed by GitHub
parent 0bfa0cc027
commit a284f50732
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -744,7 +744,7 @@ impl Flags {
.to_owned();
Some(p)
} else if module_specifier.scheme() == "npm" {
Some(std::env::current_dir().unwrap())
Some(current_dir.to_path_buf())
} else {
None
}