Skip to content

Commit

Permalink
fix(input): race condition with multiple prompts in quick succession
Browse files Browse the repository at this point in the history
  • Loading branch information
stevearc committed Dec 4, 2021
1 parent 3c01f6b commit 6be518b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/dressing/input.lua
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ return function(opts, on_confirm)
cursor[2] = cursor[2] + 1
vim.api.nvim_win_set_cursor(0, cursor)
end
on_confirm(text)
vim.schedule_wrap(on_confirm)(text)
end
if opts.highlight then
_G.dressing_prompt_hl = function()
Expand Down

0 comments on commit 6be518b

Please sign in to comment.