summaryrefslogtreecommitdiff
path: root/cli/bench/lsp_bench_standalone.rs
diff options
context:
space:
mode:
authorDavid Sherret <dsherret@users.noreply.github.com>2022-01-24 15:30:01 -0500
committerGitHub <noreply@github.com>2022-01-24 15:30:01 -0500
commitbc8de78da3c37bb5ce70547a7d3a3576d1a7734f (patch)
tree9a18157727abf271b15fc09da726c7ce4c099ccc /cli/bench/lsp_bench_standalone.rs
parent30ddf436d0d48ce0f9238f1728bc83aa4c6dddad (diff)
perf(lsp): independent diagnostic source publishes (#13427)
Diffstat (limited to 'cli/bench/lsp_bench_standalone.rs')
-rw-r--r--cli/bench/lsp_bench_standalone.rs9
1 files changed, 5 insertions, 4 deletions
diff --git a/cli/bench/lsp_bench_standalone.rs b/cli/bench/lsp_bench_standalone.rs
index 4c18a9a9d..68d2a0442 100644
--- a/cli/bench/lsp_bench_standalone.rs
+++ b/cli/bench/lsp_bench_standalone.rs
@@ -78,10 +78,11 @@ fn wait_for_deno_lint_diagnostic(
let version = msg.get("version").unwrap().as_u64().unwrap();
if document_version == version {
let diagnostics = msg.get("diagnostics").unwrap().as_array().unwrap();
- let first = &diagnostics[0];
- let source = first.get("source").unwrap().as_str().unwrap();
- if source == "deno-lint" {
- return;
+ for diagnostic in diagnostics {
+ let source = diagnostic.get("source").unwrap().as_str().unwrap();
+ if source == "deno-lint" {
+ return;
+ }
}
}
} else {