fix: diagnostics lnum starts with 1 (#892)
This commit is contained in:
@@ -1542,8 +1542,8 @@ function Sidebar:create_input(opts)
|
||||
|
||||
local diagnostics = nil
|
||||
if mentions.enable_diagnostics then
|
||||
if self.selected_code ~= nil then
|
||||
diagnostics = Utils.get_current_selection_diagnostics()
|
||||
if self.code ~= nil and self.code.bufnr ~= nil and self.code.selection ~= nil then
|
||||
diagnostics = Utils.get_current_selection_diagnostics(self.code.bufnr, self.code.selection)
|
||||
else
|
||||
diagnostics = Utils.get_diagnostics(self.code.bufnr)
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user