diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2024-04-18 21:43:28 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-19 01:43:28 +0000 |
commit | c497e766f1a136c674d8be2467eb103c85fe1d44 (patch) | |
tree | a6b84f9950f2bdca734d8d402b60d44f99605965 /cli/lsp/registries.rs | |
parent | 8e77f091ad9b1f8b3dc2eaf8b4a2be2560a67354 (diff) |
refactor: move redirect handling into deno_graph (#23444)
Diffstat (limited to 'cli/lsp/registries.rs')
-rw-r--r-- | cli/lsp/registries.rs | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/cli/lsp/registries.rs b/cli/lsp/registries.rs index b0eeb9df0..a145322b5 100644 --- a/cli/lsp/registries.rs +++ b/cli/lsp/registries.rs @@ -512,10 +512,9 @@ impl ModuleRegistry { .file_fetcher .fetch_with_options(FetchOptions { specifier, - permissions: PermissionsContainer::allow_all(), + permissions: &PermissionsContainer::allow_all(), maybe_accept: Some("application/vnd.deno.reg.v2+json, application/vnd.deno.reg.v1+json;q=0.9, application/json;q=0.8"), maybe_cache_setting: None, - maybe_checksum: None, }) .await; // if there is an error fetching, we will cache an empty file, so that @@ -609,7 +608,7 @@ impl ModuleRegistry { .ok()?; let file = self .file_fetcher - .fetch(&endpoint, PermissionsContainer::allow_all()) + .fetch(&endpoint, &PermissionsContainer::allow_all()) .await .ok()? .into_text_decoded() @@ -975,7 +974,7 @@ impl ModuleRegistry { let specifier = Url::parse(url).ok()?; let file = self .file_fetcher - .fetch(&specifier, PermissionsContainer::allow_all()) + .fetch(&specifier, &PermissionsContainer::allow_all()) .await .ok()? .into_text_decoded() @@ -1034,7 +1033,7 @@ impl ModuleRegistry { let specifier = ModuleSpecifier::parse(url).ok()?; let file = self .file_fetcher - .fetch(&specifier, PermissionsContainer::allow_all()) + .fetch(&specifier, &PermissionsContainer::allow_all()) .await .map_err(|err| { error!( @@ -1072,7 +1071,7 @@ impl ModuleRegistry { .ok()?; let file = self .file_fetcher - .fetch(&specifier, PermissionsContainer::allow_all()) + .fetch(&specifier, &PermissionsContainer::allow_all()) .await .map_err(|err| { error!( |