diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2023-04-12 08:36:11 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-12 08:36:11 -0400 |
commit | 0e3f62d4446ae7b9a64dacf7befcaecede118222 (patch) | |
tree | fc1cbbbb294e61bb61e8d8ed89fa50cc9e9efa34 /cli/proc_state.rs | |
parent | 806671af3345f403d122911d8a3f09a2994bb8c0 (diff) |
fix(npm): cache bust npm specifiers more aggressively (#18636)
Part 1: #18622
Part 2: This PR
Closes #16901
---------
Co-authored-by: Luca Casonato <hello@lcas.dev>
Diffstat (limited to 'cli/proc_state.rs')
-rw-r--r-- | cli/proc_state.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/cli/proc_state.rs b/cli/proc_state.rs index d3a0618ef..659e2d1db 100644 --- a/cli/proc_state.rs +++ b/cli/proc_state.rs @@ -26,9 +26,9 @@ use crate::http_util::HttpClient; use crate::node; use crate::node::NodeResolution; use crate::npm::create_npm_fs_resolver; +use crate::npm::CliNpmRegistryApi; use crate::npm::NpmCache; use crate::npm::NpmPackageResolver; -use crate::npm::NpmRegistry; use crate::npm::NpmResolution; use crate::npm::PackageJsonDepsInstaller; use crate::resolver::CliGraphResolver; @@ -95,7 +95,7 @@ pub struct Inner { pub resolver: Arc<CliGraphResolver>, maybe_file_watcher_reporter: Option<FileWatcherReporter>, pub node_analysis_cache: NodeAnalysisCache, - pub npm_api: NpmRegistry, + pub npm_api: CliNpmRegistryApi, pub npm_cache: NpmCache, pub npm_resolver: NpmPackageResolver, pub npm_resolution: NpmResolution, @@ -233,14 +233,14 @@ impl ProcState { let lockfile = cli_options.maybe_lock_file(); - let npm_registry_url = NpmRegistry::default_url().to_owned(); + let npm_registry_url = CliNpmRegistryApi::default_url().to_owned(); let npm_cache = NpmCache::from_deno_dir( &dir, cli_options.cache_setting(), http_client.clone(), progress_bar.clone(), ); - let npm_api = NpmRegistry::new( + let npm_api = CliNpmRegistryApi::new( npm_registry_url.clone(), npm_cache.clone(), http_client.clone(), |