From 0fb49d56376a7db652aa6ad78e91c4d03458b978 Mon Sep 17 00:00:00 2001 From: Paul Loyd Date: Tue, 1 Aug 2023 14:00:11 +0400 Subject: [PATCH] fix(network/codec): decode response right way --- elfo-network/src/codec/decode.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/elfo-network/src/codec/decode.rs b/elfo-network/src/codec/decode.rs index 42cfacb8..ce37a10c 100644 --- a/elfo-network/src/codec/decode.rs +++ b/elfo-network/src/codec/decode.rs @@ -243,7 +243,7 @@ fn do_decode(frame: &mut Cursor<&[u8]>) -> Result KIND_RESPONSE_OK => { let request_id = get_request_id(frame)?; Response { - request_id: get_request_id(frame)?, + request_id, message: Ok(map_decode_error(get_message(frame), Some(request_id))?), is_last: flags & FLAG_IS_LAST_RESPONSE != 0, }