From 204b699be4cf88e216572d77ad4cced9ab4748bc Mon Sep 17 00:00:00 2001 From: Aaron O'Mullan Date: Sun, 18 Apr 2021 07:29:37 +0200 Subject: [PATCH] chore(cli/lsp): fix 2 lint errors (#10228) 1. error: called `.iter().count()` on a `Vec` 2. error: inconsistent struct constructor --- cli/lsp/registries.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cli/lsp/registries.rs b/cli/lsp/registries.rs index 8a9ac20c65..877f03be33 100644 --- a/cli/lsp/registries.rs +++ b/cli/lsp/registries.rs @@ -493,8 +493,8 @@ impl ModuleRegistry { label, kind, detail, - filter_text, sort_text, + filter_text, text_edit, command, ..Default::default() @@ -958,7 +958,7 @@ mod tests { let actual = parse_replacement_variables( "https://deno.land/_vsc1/modules/${module}/v/${{version}}", ); - assert_eq!(actual.iter().count(), 2); + assert_eq!(actual.len(), 2); assert!(actual.contains(&"module".to_owned())); assert!(actual.contains(&"version".to_owned())); }