diff options
author | Leo Kettmeir <crowlkats@toaxl.com> | 2023-05-27 15:42:20 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-27 15:42:20 +0200 |
commit | be59e93220e24a2e66ae2843a136e61eab9d8ac3 (patch) | |
tree | 9c49d56516d1f126234d4e11e276750c6028b42a /runtime/permissions/mod.rs | |
parent | d0c5ff42f4b5fa9b848e6ed5af2e480d12f15bda (diff) |
refactor(node/http): don't use readablestream for writing to request (#19282)
Refactors the internal usage of a readablestream to write to the
resource directly
---------
Co-authored-by: Bartek IwaĆczuk <biwanczuk@gmail.com>
Diffstat (limited to 'runtime/permissions/mod.rs')
-rw-r--r-- | runtime/permissions/mod.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/runtime/permissions/mod.rs b/runtime/permissions/mod.rs index 6cce7d1e9..f1d0362ca 100644 --- a/runtime/permissions/mod.rs +++ b/runtime/permissions/mod.rs @@ -13,6 +13,7 @@ use deno_core::serde::Deserializer; use deno_core::serde::Serialize; use deno_core::serde_json; use deno_core::url; +use deno_core::url::Url; use deno_core::ModuleSpecifier; use deno_core::OpState; use log; @@ -1872,6 +1873,15 @@ impl PermissionsContainer { impl deno_node::NodePermissions for PermissionsContainer { #[inline(always)] + fn check_net_url( + &mut self, + url: &Url, + api_name: &str, + ) -> Result<(), AnyError> { + self.0.lock().net.check_url(url, Some(api_name)) + } + + #[inline(always)] fn check_read(&self, path: &Path) -> Result<(), AnyError> { self.0.lock().read.check(path, None) } |