mirror of
https://github.com/neovim/neovim.git
synced 2026-02-09 05:18:45 +00:00
Problem: `Client.on_exit` runs `Client._on_detach` and the client removal logic within two separate `vim.schedule` sequentially. However, since `Client._on_detach` executes `LspNotify` inside `vim.schedule`, this causes `LspNotify` to be executed after the client removal, which is scheduled first. At that point, a valid `Client` can no longer be retrieved within the autocmd callback. Solution: Put the client deletion inside the `vim.schedule` call.