diff options
Diffstat (limited to 'crates/server/src/io.rs')
-rw-r--r-- | crates/server/src/io.rs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/crates/server/src/io.rs b/crates/server/src/io.rs index 5eafc6942..f247327ab 100644 --- a/crates/server/src/io.rs +++ b/crates/server/src/io.rs | |||
@@ -34,8 +34,13 @@ pub struct RawNotification { | |||
34 | 34 | ||
35 | #[derive(Debug, Serialize, Deserialize)] | 35 | #[derive(Debug, Serialize, Deserialize)] |
36 | pub struct RawResponse { | 36 | pub struct RawResponse { |
37 | pub id: Option<u64>, | 37 | // JSON RPC allows this to be null if it was impossible |
38 | // to decode the request's id. Ignore this special case | ||
39 | // and just die horribly. | ||
40 | pub id: u64, | ||
41 | #[serde(default)] | ||
38 | pub result: Value, | 42 | pub result: Value, |
43 | #[serde(default)] | ||
39 | pub error: Value, | 44 | pub error: Value, |
40 | } | 45 | } |
41 | 46 | ||