Skip to content

Commit 7fbb0a4

Browse files
committed
feat: only refresh codelens for buffer
1 parent 0ed4fb3 commit 7fbb0a4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lua/astrolsp/init.lua

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,9 @@ end
8080
---@param client table The LSP client details when attaching
8181
---@param bufnr integer The buffer that the LSP client is attaching to
8282
M.on_attach = function(client, bufnr)
83-
if client.supports_method "textDocument/codeLens" and M.config.features.codelens then vim.lsp.codelens.refresh() end
83+
if client.supports_method "textDocument/codeLens" and M.config.features.codelens then
84+
vim.lsp.codelens.refresh { bufnr = bufnr }
85+
end
8486

8587
local formatting_disabled = vim.tbl_get(M.config, "formatting", "disabled")
8688
if

0 commit comments

Comments
 (0)