commit 1670fbee0f57af9aa9c43f448d92870cf0407285
parent 276860b5380de8f0a7abf0ad58e70ef0f59f32c4
Author: Stephan Seitz <stephan.seitz@fau.de>
Date: Thu, 24 Apr 2025 21:21:23 +0200
fix(docs) fix syntax error in Lua snippet for `vim.lsp.document_color` #33612
9ff1239634 added support for 'textDocument/documentColor' but the
text snippet in the Lua docs seem to contain a syntax error.
Diffstat:
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/runtime/doc/lsp.txt b/runtime/doc/lsp.txt
@@ -2167,7 +2167,7 @@ enable({enable}, {bufnr}, {opts}) *vim.lsp.document_color.enable()*
callback = function(args)
local client = vim.lsp.get_client_by_id(args.data.client_id)
- if client:supports_method('textDocument/documentColor')
+ if client:supports_method('textDocument/documentColor') then
vim.lsp.document_color.enable(true, args.buf)
end
end
diff --git a/runtime/lua/vim/lsp/document_color.lua b/runtime/lua/vim/lsp/document_color.lua
@@ -248,7 +248,7 @@ end
--- callback = function(args)
--- local client = vim.lsp.get_client_by_id(args.data.client_id)
---
---- if client:supports_method('textDocument/documentColor')
+--- if client:supports_method('textDocument/documentColor') then
--- vim.lsp.document_color.enable(true, args.buf)
--- end
--- end