Skip to content

Commit

Permalink
Respect *.suggest.enable
Browse files Browse the repository at this point in the history
  • Loading branch information
cooolbros committed Jan 14, 2025
1 parent 885d5c2 commit 7cc67cb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/server/src/LanguageServer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -547,6 +547,11 @@ export abstract class LanguageServer<
private async onCompletion(params: TextDocumentRequestParams<CompletionParams>) {
try {
using document = await this.documents.get(params.textDocument.uri)
const configuration = await firstValueFrom(document.documentConfiguration$)
if (!configuration[this.languageId].suggest.enable) {
return null
}

const items = await this.getCompletion(
document,
new VDFPosition(params.position.line, params.position.character),
Expand Down

0 comments on commit 7cc67cb

Please sign in to comment.