Skip to content

Commit a726171

Browse files
committed
fix(nvim): use stop_client instead of enable to disable LSP in fugitive buffers
1 parent ca9774a commit a726171

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lua/plugins/fugitive.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ return {
3232
vim.keymap.set("n", "q", ":tabclose<CR>", { buffer = true, silent = true })
3333
local bufname = vim.api.nvim_buf_get_name(0)
3434
if vim.startswith(bufname, "fugitive://") then
35-
vim.lsp.enable(false, { bufnr = vim.api.nvim_get_current_buf() })
35+
vim.lsp.stop_client(vim.lsp.get_clients({ bufnr = vim.api.nvim_get_current_buf() }))
3636
end
3737
end)
3838
end

0 commit comments

Comments
 (0)