mirror of
https://github.com/LunarVim/LunarVim.git
synced 2024-09-20 10:35:08 +02:00
fix: discard invalid choice when closing buffers (#3488)
This commit is contained in:
parent
b42e8c3c73
commit
a8957a9d36
1 changed files with 1 additions and 1 deletions
|
@ -194,7 +194,7 @@ function M.buf_kill(kill_command, bufnr, force)
|
|||
vim.ui.input({
|
||||
prompt = string.format([[%s. Close it anyway? [y]es or [n]o (default: no): ]], warning),
|
||||
}, function(choice)
|
||||
if choice:match "ye?s?" then force = true end
|
||||
if choice ~= nil and choice:match "ye?s?" then force = true end
|
||||
end)
|
||||
if not force then return end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue