mirror of
https://github.com/neovim/neovim
synced 2025-07-16 01:01:49 +00:00
fix(lsp): support false
result in handlers (#20252)
Closes https://github.com/neovim/neovim/issues/20111
This commit is contained in:
committed by
GitHub
parent
a0e6e767a6
commit
10196f1b46
@ -405,8 +405,7 @@ function Client:handle_body(body)
|
||||
{ status = status, result = result, err = err }
|
||||
)
|
||||
if status then
|
||||
if not (result or err) then
|
||||
-- TODO this can be a problem if `null` is sent for result. needs vim.NIL
|
||||
if result == nil and err == nil then
|
||||
error(
|
||||
string.format(
|
||||
'method %q: either a result or an error must be sent to the server in response',
|
||||
|
Reference in New Issue
Block a user