diff options
author | Raphael <glephunter@gmail.com> | 2023-08-05 17:03:57 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-05 02:03:57 -0700 |
commit | 42630923fc00633d806af97c1792b2ed4a71e1cc (patch) | |
tree | ccf231bfe04b1ff963a39b6fd703c68c527dfa60 /runtime/lua/vim/lsp.lua | |
parent | 1f252a8ac0d1ca23777978fcef07bd7fab309494 (diff) | |
download | rneovim-42630923fc00633d806af97c1792b2ed4a71e1cc.tar.gz rneovim-42630923fc00633d806af97c1792b2ed4a71e1cc.tar.bz2 rneovim-42630923fc00633d806af97c1792b2ed4a71e1cc.zip |
refactor(lsp): use protocol.Methods instead of strings #24570
Diffstat (limited to 'runtime/lua/vim/lsp.lua')
-rw-r--r-- | runtime/lua/vim/lsp.lua | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/runtime/lua/vim/lsp.lua b/runtime/lua/vim/lsp.lua index ea6b386b28..bfba275c33 100644 --- a/runtime/lua/vim/lsp.lua +++ b/runtime/lua/vim/lsp.lua @@ -1612,7 +1612,7 @@ function lsp.start_client(config) data = { client_id = client_id, request_id = id, request = request }, }) end - return rpc.notify('$/cancelRequest', { id = id }) + return rpc.notify(ms.dollar_cancelRequest, { id = id }) end -- Track this so that we can escalate automatically if we've already tried a @@ -1636,9 +1636,9 @@ function lsp.start_client(config) return end -- Sending a signal after a process has exited is acceptable. - rpc.request('shutdown', nil, function(err, _) + rpc.request(ms.shutdown, nil, function(err, _) if err == nil then - rpc.notify('exit') + rpc.notify(ms.exit) else -- If there was an error in the shutdown request, then term to be safe. rpc.terminate() |