minor: bump lsp-server version

This commit is contained in:
Lukas Wirth
2022-04-09 00:13:47 +02:00
parent b8ed4a388c
commit 2d445de170
4 changed files with 13 additions and 5 deletions

View File

@@ -1,6 +1,7 @@
//! See [RequestDispatcher].
use std::{fmt, panic, thread};
use lsp_server::ExtractError;
use serde::{de::DeserializeOwned, Serialize};
use crate::{
@@ -234,7 +235,10 @@ impl<'a> NotificationDispatcher<'a> {
};
let params = match not.extract::<N::Params>(N::METHOD) {
Ok(it) => it,
Err(not) => {
Err(ExtractError::JsonError { method, error }) => {
panic!("Invalid request\nMethod: {method}\n error: {error}",)
}
Err(ExtractError::MethodMismatch(not)) => {
self.not = Some(not);
return Ok(self);
}