diff --git a/lua/core/utils.lua b/lua/core/utils.lua index ed533f6..243664c 100644 --- a/lua/core/utils.lua +++ b/lua/core/utils.lua @@ -175,7 +175,11 @@ M.packer_sync = function(...) end M.bufilter = function() - local bufs = vim.t.bufs + local bufs = vim.t.bufs or nil + + if not bufs then + return {} + end for i = #bufs, 1, -1 do if not vim.api.nvim_buf_is_valid(bufs[i]) then