We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c8a422d commit 4b59d4cCopy full SHA for 4b59d4c
1 file changed
lua/copilot/client.lua
@@ -5,7 +5,7 @@ M.buf_attach_copilot = function()
5
if vim.tbl_contains(M.params.ft_disable, vim.bo.filetype) then return end
6
if not vim.bo.buflisted or not vim.bo.buftype == "" then return end
7
local client_id = util.find_copilot_client()
8
- local buf_clients = vim.lsp.get_active_clients(0)
+ local buf_clients = vim.lsp.get_active_clients({ bufnr = 0 })
9
if not buf_clients and client_id or (client_id and not buf_clients[client_id]) then
10
vim.lsp.buf_attach_client(0, client_id)
11
end
0 commit comments