From 3f8bbc60e1b71e75c477709eb1cd694ec5c7d8cf Mon Sep 17 00:00:00 2001 From: David Sherret Date: Thu, 11 May 2023 19:05:37 -0400 Subject: [PATCH] fix(ext/fs): add more context_path (#19101) --- ext/fs/ops.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ext/fs/ops.rs b/ext/fs/ops.rs index 71526b217a..0fad92044c 100644 --- a/ext/fs/ops.rs +++ b/ext/fs/ops.rs @@ -1154,7 +1154,7 @@ where permissions.check_read(&path, "Deno.readFileSync()")?; let fs = state.borrow::(); - let buf = fs.read_file_sync(&path).context("readfile")?; + let buf = fs.read_file_sync(&path).context_path("readfile", &path)?; Ok(buf.into()) } @@ -1210,7 +1210,7 @@ where permissions.check_read(&path, "Deno.readFileSync()")?; let fs = state.borrow::(); - let buf = fs.read_file_sync(&path).context("readfile")?; + let buf = fs.read_file_sync(&path).context_path("readfile", &path)?; Ok(string_from_utf8_lossy(buf)) }