From f31b7d7d17f7a7a371d78a205e2e4a2ee6846a22 Mon Sep 17 00:00:00 2001 From: Tobie Morgan Hitchcock Date: Fri, 14 Oct 2022 07:56:35 +0100 Subject: [PATCH] Allow number values for JSON RPC `id` field --- src/net/rpc.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/net/rpc.rs b/src/net/rpc.rs index 4454866a..ecd8c2a3 100644 --- a/src/net/rpc.rs +++ b/src/net/rpc.rs @@ -114,6 +114,7 @@ impl Rpc { let id = match req.pick(&*ID) { Value::Uuid(v) => Some(v.to_raw()), Value::Strand(v) => Some(v.to_raw()), + Value::Number(v) => Some(v.to_string()), _ => return Response::failure(None, Failure::INVALID_REQUEST).send(chn).await, }; // Fetch the 'method' argument