diff options
| author | Vsevolod <kefirchik3@gmail.com> | 2021-10-24 17:01:18 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-10-24 16:01:18 +0200 |
| commit | 782d802d44077e07f80189560f91c86370f11e39 (patch) | |
| tree | 1f6d563de26a910ca4dc97327bfbe9a8bc5f489c /lua/telescope/pickers/scroller.lua | |
| parent | f31ef362931907bbdd3b46cb880b34493c2d1882 (diff) | |
fix: missing check for negative index in cycle scrolling (#1372)
Diffstat (limited to 'lua/telescope/pickers/scroller.lua')
| -rw-r--r-- | lua/telescope/pickers/scroller.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lua/telescope/pickers/scroller.lua b/lua/telescope/pickers/scroller.lua index 8b9bbd5..a658f68 100644 --- a/lua/telescope/pickers/scroller.lua +++ b/lua/telescope/pickers/scroller.lua @@ -18,7 +18,7 @@ local scroll_calculators = { if row >= finish then return start elseif row < start then - return finish - 1 + return (finish - 1 < 0) and finish or finish - 1 end return row |
