Skip to content

Commit

Permalink
fix(blame): check win is valid after running blame
Browse files Browse the repository at this point in the history
  • Loading branch information
lewis6991 committed Apr 18, 2024
1 parent 4475b3e commit 7e38f07
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lua/gitsigns/current_line_blame.lua
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,10 @@ local function update0(bufnr)

local blame_info = bcache:get_blame(lnum, opts)

if not api.nvim_win_is_valid(winid) or bufnr ~= api.nvim_win_get_buf(winid) then
return
end

if not blame_info then
return
end
Expand Down

0 comments on commit 7e38f07

Please sign in to comment.