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

Commit

Permalink
Changed to ignore publishDiagnostic updates for windows other than th…
Browse files Browse the repository at this point in the history
…e current one
  • Loading branch information
svermeulen committed Oct 17, 2020
1 parent bef1c61 commit d89c7db
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lua/diagnostic.lua
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ function M.modifyCallback()
vim.lsp.err_message("LSP.publishDiagnostics: Couldn't find buffer for ", uri)
return
end
if vim.api.nvim_win_get_buf(vim.api.nvim_get_current_win()) ~= bufnr then
return
end
get_diagnostics_count(result.diagnostics, bufnr)
if vim.api.nvim_get_var('diagnostic_level') ~= nil then
result.diagnostics = remove_diagnostics(result.diagnostics)
Expand Down

0 comments on commit d89c7db

Please sign in to comment.