docs(diagnostic): fix indentation in diagnostic-on-jump-example (#37516)

This commit is contained in:
Aymen Hafeez
2026-01-25 20:11:01 +00:00
committed by GitHub
parent d93e150888
commit 8c0c34786e

View File

@@ -197,14 +197,14 @@ following uses the `virtual_lines` handler when jumping to a diagnostic: >lua
--- @param diagnostic? vim.Diagnostic
--- @param bufnr integer
local function on_jump(diagnostic, bufnr)
if not diagnostic then return end
if not diagnostic then return end
vim.diagnostic.show(
virt_lines_ns,
bufnr,
{ diagnostic },
{ virtual_lines = { current_line = true }, virtual_text = false }
)
vim.diagnostic.show(
virt_lines_ns,
bufnr,
{ diagnostic },
{ virtual_lines = { current_line = true }, virtual_text = false }
)
end
vim.diagnostic.config({ jump = { on_jump = on_jump } })