Skip to content

Commit

Permalink
fix: jumplist picker indexing the line after (#2273)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hippo0o committed Dec 21, 2022
1 parent d16581e commit e960efa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/telescope/builtin/__internal.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1353,7 +1353,7 @@ internal.jumplist = function(opts)
local sorted_jumplist = {}
for i = #jumplist, 1, -1 do
if vim.api.nvim_buf_is_valid(jumplist[i].bufnr) then
jumplist[i].text = vim.api.nvim_buf_get_lines(jumplist[i].bufnr, jumplist[i].lnum, jumplist[i].lnum + 1, false)[1]
jumplist[i].text = vim.api.nvim_buf_get_lines(jumplist[i].bufnr, jumplist[i].lnum - 1, jumplist[i].lnum, false)[1]
or ""
table.insert(sorted_jumplist, jumplist[i])
end
Expand Down

0 comments on commit e960efa

Please sign in to comment.