diff options
| author | Florian Fischer <florian.fischer@muhq.space> | 2023-01-18 15:11:31 +0100 |
|---|---|---|
| committer | Florian Fischer <florian.fischer@muhq.space> | 2023-01-18 15:11:31 +0100 |
| commit | 5dca999fd21c261fea34ddeca7bfad2cb531dbce (patch) | |
| tree | ee691e575634e4e1d96d5675452fd7fe42c254f2 /init.lua | |
| parent | 6b5676791531a6b465661430077997f41caf84d8 (diff) | |
| download | vis-lspc-5dca999fd21c261fea34ddeca7bfad2cb531dbce.tar.gz vis-lspc-5dca999fd21c261fea34ddeca7bfad2cb531dbce.zip | |
distinguish between method call and method response
We can not only use the fact that we have a method call inflight with
the observed id. Because the language server may has called a method
on use with the same id.
Therefore we have to also check if the incoming message contains
a method field.
method + id -> method call
id -> method response
method -> notification
Diffstat (limited to 'init.lua')
| -rw-r--r-- | init.lua | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -914,7 +914,7 @@ end -- for a message response we have a req remembered in the inflight table local function ls_handle_method(ls, method) local req = ls.inflight[method.id] - if req then + if req and not method.method then ls_handle_method_response(ls, method, req) else ls_handle_method_call(ls, method) |
