mirror of
https://github.com/neovim/neovim.git
synced 2025-09-07 11:58:17 +00:00
lsp: remove buffer version on buffer_detach (#12029)
When we save the buffer, the buffer is detached and attached again. So the client also needs to remove the buffer version once.
This commit is contained in:
@@ -198,6 +198,7 @@ local function text_document_did_open_handler(bufnr, client)
|
||||
}
|
||||
}
|
||||
client.notify('textDocument/didOpen', params)
|
||||
util.buf_versions[bufnr] = params.textDocument.version
|
||||
end
|
||||
|
||||
--- LSP client object.
|
||||
@@ -722,6 +723,7 @@ function lsp.buf_attach_client(bufnr, client_id)
|
||||
client.notify('textDocument/didClose', params)
|
||||
end
|
||||
end)
|
||||
util.buf_versions[bufnr] = nil
|
||||
all_buffer_active_clients[bufnr] = nil
|
||||
end;
|
||||
-- TODO if we know all of the potential clients ahead of time, then we
|
||||
|
Reference in New Issue
Block a user