Skip to content

Commit

Permalink
fix(explorer): don't try to show when closed. Fixes #836
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed Jan 31, 2025
1 parent 253b2a2 commit 6921cd0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lua/snacks/picker/source/explorer.lua
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,10 @@ function State:show(path)
return
end
local function show()
local picker = self.picker()
if not picker or picker.closed then
return
end
for item, idx in picker:iter() do
if item.file == path then
picker.list:view(idx)
Expand Down

0 comments on commit 6921cd0

Please sign in to comment.