stevearc / aerial.nvim

Neovim plugin for a code outline window
MIT License
1.55k stars 76 forks source link

check if bufdata.last_win != nil #356

Closed linusboehm closed 3 months ago

linusboehm commented 3 months ago

When opening nvim in diffview (nvim -c DiffviewOpen) and then toggeling aerial, aerial errors when trying to call vim.api.nvim_win_is_valid(bufdata.last_win) as bufdata.last_win == nil. This change adds a check and returns in case of a nil value.

stevearc commented 3 months ago

LGTM thanks!