fix: don't error when no hidden buffers are available (#341)

This commit is contained in:
Senghan Bright
2020-12-16 21:36:50 +01:00
committed by GitHub
parent af8d990c2c
commit 205790285b

View File

@@ -437,6 +437,7 @@ internal.buffers = function(opts)
or vim.api.nvim_buf_is_loaded(b))
and 1 == vim.fn.buflisted(b)
end, vim.api.nvim_list_bufs())
if not next(bufnrs) then return end
local buffers = {}
local default_selection_idx = 1