Skip to content

Commit

Permalink
fix(core): do not clear context on interface swap (#1810)
Browse files Browse the repository at this point in the history
  • Loading branch information
ibhagwan committed Feb 9, 2025
1 parent 81c5256 commit b3e9303
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lua/fzf-lua/core.lua
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,11 @@ M.fzf = function(contents, opts)
and (action[1] ~= nil or action.reload or action.noclose or action.reuse)
if (not fzf_win:autoclose() == false) and not do_not_close then
fzf_win:close(fzf_bufnr)
M.__CTX = nil
-- only clear context if we didn't open a new interface, for example, opening
-- files, switching to normal with <c-\><c-n> and opening buffers (#1810)
if utils.fzf_winobj() == nil then
M.__CTX = nil
end
end
return selected
end
Expand Down

0 comments on commit b3e9303

Please sign in to comment.