Skip to content

Commit

Permalink
fix(previewer): scroll with zero fzf matches (#1600)
Browse files Browse the repository at this point in the history
  • Loading branch information
phanen authored and ibhagwan committed Dec 19, 2024
1 parent 8a5eb31 commit 8e6a1e9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/fzf-lua/previewer/builtin.lua
Original file line number Diff line number Diff line change
Expand Up @@ -444,7 +444,7 @@ end

function Previewer.base:scroll(direction)
local preview_winid = self.win.preview_winid
if preview_winid < 0 or not direction then return end
if not self.preview_bufnr or preview_winid < 0 or not direction then return end
if not api.nvim_win_is_valid(preview_winid) then return end

if direction == "reset" then
Expand Down

0 comments on commit 8e6a1e9

Please sign in to comment.