Skip to content

Commit 5905ef6

Browse files
committed
Simplify getTagCompletions
1 parent d173f7b commit 5905ef6

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

server/src/server.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -752,18 +752,14 @@ function getTagCompletions(): CompletionItem[] {
752752
}
753753

754754
function getWhereClauseCompletions(): CompletionItem[] {
755-
const completions: CompletionItem[] = [];
756-
757-
completions.push({
755+
return [{
758756
label: ". identifier = expression",
759757
kind: CompletionItemKind.Snippet,
760758
detail: "Where clause",
761759
documentation: "Define a variable in a where clause",
762760
insertText: ". ${1:identifier} = ${2:expression}",
763761
insertTextFormat: InsertTextFormat.Snippet,
764-
});
765-
766-
return [...completions, ...getGlobalCompletions()];
762+
}, ...getGlobalCompletions()];
767763
}
768764

769765
function getPatternMatchCompletions(): CompletionItem[] {

0 commit comments

Comments
 (0)