summaryrefslogtreecommitdiff
path: root/cli/lsp/documents.rs
diff options
context:
space:
mode:
authorKitson Kelly <me@kitsonkelly.com>2021-04-20 07:10:43 +1000
committerGitHub <noreply@github.com>2021-04-20 07:10:43 +1000
commit65f7a021f092f2c475969a6f6762ab5e35d65123 (patch)
tree008dec74a2d1ac88a59db15e0e8a78ed02ae6011 /cli/lsp/documents.rs
parentd6233100bd6a5c5b2a1c541f580cc47053f6f90d (diff)
feat(lsp): improve diagnostic status page (#10253)
Diffstat (limited to 'cli/lsp/documents.rs')
-rw-r--r--cli/lsp/documents.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/cli/lsp/documents.rs b/cli/lsp/documents.rs
index 47a23eb49..ef37396a2 100644
--- a/cli/lsp/documents.rs
+++ b/cli/lsp/documents.rs
@@ -202,6 +202,10 @@ impl DocumentCache {
}
}
+ pub fn specifiers(&self) -> Vec<ModuleSpecifier> {
+ self.docs.keys().cloned().collect()
+ }
+
pub fn version(&self, specifier: &ModuleSpecifier) -> Option<i32> {
self.docs.get(specifier).and_then(|doc| doc.version)
}