Skip to content
This repository was archived by the owner on Jul 6, 2021. It is now read-only.

Commit d89c7db

Browse files
committed
Changed to ignore publishDiagnostic updates for windows other than the current one
1 parent bef1c61 commit d89c7db

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lua/diagnostic.lua

+3
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,9 @@ function M.modifyCallback()
4444
vim.lsp.err_message("LSP.publishDiagnostics: Couldn't find buffer for ", uri)
4545
return
4646
end
47+
if vim.api.nvim_win_get_buf(vim.api.nvim_get_current_win()) ~= bufnr then
48+
return
49+
end
4750
get_diagnostics_count(result.diagnostics, bufnr)
4851
if vim.api.nvim_get_var('diagnostic_level') ~= nil then
4952
result.diagnostics = remove_diagnostics(result.diagnostics)

0 commit comments

Comments
 (0)