aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/diagnostic.lua
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/lua/vim/diagnostic.lua')
-rw-r--r--runtime/lua/vim/diagnostic.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/runtime/lua/vim/diagnostic.lua b/runtime/lua/vim/diagnostic.lua
index 1e7f95a353..00e4301fa0 100644
--- a/runtime/lua/vim/diagnostic.lua
+++ b/runtime/lua/vim/diagnostic.lua
@@ -1073,6 +1073,7 @@ function M.show_line_diagnostics(opts, bufnr, lnum)
opts = opts or {}
opts.focus_id = "line_diagnostics"
opts.lnum = lnum or (vim.api.nvim_win_get_cursor(0)[1] - 1)
+ bufnr = get_bufnr(bufnr)
local line_diagnostics = M.get(bufnr, opts)
return show_diagnostics(opts, line_diagnostics)
end