Clippy clean

This commit is contained in:
Sunli 2022-04-08 09:41:23 +08:00
parent 3390682a73
commit 8d6066ef82
1 changed files with 2 additions and 2 deletions

View File

@ -111,6 +111,6 @@ pub async fn receive_batch_cbor(body: impl AsyncRead) -> Result<BatchRequest, Pa
body.read_to_end(&mut data)
.await
.map_err(ParseRequestError::Io)?;
Ok(serde_cbor::from_slice::<BatchRequest>(&data)
.map_err(|e| ParseRequestError::InvalidRequest(Box::new(e)))?)
serde_cbor::from_slice::<BatchRequest>(&data)
.map_err(|e| ParseRequestError::InvalidRequest(Box::new(e)))
}