* fix(#3041): use vim.diagnostic.get for updating diagnostics * fix(#3041): remove unnecessary @type --------- Co-authored-by: Alexander Courtis <alex@courtis.org>
This commit is contained in:
parent
68fc4c20f5
commit
aae01853dd
@ -128,8 +128,7 @@ function M.update_lsp(ev)
|
|||||||
|
|
||||||
local profile_event = log.profile_start("DiagnosticChanged event")
|
local profile_event = log.profile_start("DiagnosticChanged event")
|
||||||
|
|
||||||
---@type vim.Diagnostic[]
|
local diagnostics = vim.diagnostic.get(ev.buf)
|
||||||
local diagnostics = ev.data.diagnostics
|
|
||||||
|
|
||||||
-- use the buffer from the event, as ev.data.diagnostics will be empty on resolved diagnostics
|
-- use the buffer from the event, as ev.data.diagnostics will be empty on resolved diagnostics
|
||||||
local bufname = uniformize_path(vim.api.nvim_buf_get_name(ev.buf))
|
local bufname = uniformize_path(vim.api.nvim_buf_get_name(ev.buf))
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user