fix(lsp): explicitly pass bufnr in didSave handler (#16906)

Addresses a regression introduced by the stricter type checking
in lua api functions from https://github.com/neovim/neovim/pull/16745
This commit is contained in:
Michael Lingelbach 2022-01-03 21:03:16 -05:00 committed by GitHub
parent efe6485aca
commit 207307d0fa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1131,7 +1131,7 @@ function lsp._text_document_did_save_handler(bufnr)
if client.resolved_capabilities.text_document_save then if client.resolved_capabilities.text_document_save then
local included_text local included_text
if client.resolved_capabilities.text_document_save_include_text then if client.resolved_capabilities.text_document_save_include_text then
included_text = text() included_text = text(bufnr)
end end
client.notify('textDocument/didSave', { client.notify('textDocument/didSave', {
textDocument = { textDocument = {