We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cc01af0 commit b3a8a4fCopy full SHA for b3a8a4f
lua/diffview/lib.lua
@@ -200,7 +200,7 @@ function M.is_buf_in_use(bufnr)
200
for _, view in ipairs(M.views) do
201
if view:instanceof(StandardView.__get()) then
202
---@cast view StandardView
203
- for _, file in ipairs(view.cur_entry.layout:files()) do
+ for _, file in ipairs(view.cur_entry and view.cur_entry.layout:files() or {}) do
204
if file:is_valid() and file.bufnr == bufnr then
205
return true
206
end
0 commit comments