diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2023-08-08 10:23:02 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-08 14:23:02 +0000 |
commit | 05f838a57cc5b5e7b262e1640baa4d93dfb0df28 (patch) | |
tree | f13f97b5988c537023c05033bf862c52e74d080c /cli/lsp/language_server.rs | |
parent | a037ed77a2b2dbef1d2c4175c0401738a13f13bd (diff) |
refactor: use deno_cache_dir crate (#20092)
Uses https://github.com/denoland/deno_cache/pull/26
Diffstat (limited to 'cli/lsp/language_server.rs')
-rw-r--r-- | cli/lsp/language_server.rs | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/cli/lsp/language_server.rs b/cli/lsp/language_server.rs index 7a13e2396..5b9ba94f1 100644 --- a/cli/lsp/language_server.rs +++ b/cli/lsp/language_server.rs @@ -555,7 +555,10 @@ impl Inner { http_client.clone(), ); let location = dir.deps_folder_path(); - let deps_http_cache = Arc::new(GlobalHttpCache::new(location)); + let deps_http_cache = Arc::new(GlobalHttpCache::new( + location, + crate::cache::RealDenoCacheEnv, + )); let documents = Documents::new(deps_http_cache.clone()); let cache_metadata = cache::CacheMetadata::new(deps_http_cache.clone()); let performance = Arc::new(Performance::default()); @@ -904,7 +907,10 @@ impl Inner { ); self.module_registries_location = module_registries_location; // update the cache path - let global_cache = Arc::new(GlobalHttpCache::new(dir.deps_folder_path())); + let global_cache = Arc::new(GlobalHttpCache::new( + dir.deps_folder_path(), + crate::cache::RealDenoCacheEnv, + )); let maybe_local_cache = self.config.maybe_vendor_dir_path().map(|local_path| { Arc::new(LocalLspHttpCache::new(local_path, global_cache.clone())) |