diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2023-12-04 16:05:40 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-04 21:05:40 +0000 |
commit | a24d3e8763bc48b69936db9231efb76766914303 (patch) | |
tree | 7091c5354d1e341c34e5847ea0271213c8730c69 /runtime/permissions/mod.rs | |
parent | 9eb25e3cff22d1f704ede0d4066abc846a26a919 (diff) |
perf(node/fs): faster `existsSync` when not exists (#21458)
Diffstat (limited to 'runtime/permissions/mod.rs')
-rw-r--r-- | runtime/permissions/mod.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/runtime/permissions/mod.rs b/runtime/permissions/mod.rs index 75d4af1c7..7677b5c36 100644 --- a/runtime/permissions/mod.rs +++ b/runtime/permissions/mod.rs @@ -1376,8 +1376,12 @@ impl deno_node::NodePermissions for PermissionsContainer { } #[inline(always)] - fn check_read(&self, path: &Path) -> Result<(), AnyError> { - self.0.lock().read.check(path, None) + fn check_read_with_api_name( + &self, + path: &Path, + api_name: Option<&str>, + ) -> Result<(), AnyError> { + self.0.lock().read.check(path, api_name) } fn check_sys(&self, kind: &str, api_name: &str) -> Result<(), AnyError> { |