not unwraping, and passing err over requester
This commit is contained in:
parent
1d0e9c379b
commit
61242718e9
@ -11,7 +11,7 @@ impl Requester {
|
||||
where
|
||||
T: DeserializeOwned,
|
||||
{
|
||||
let body = req.collect().await.unwrap().to_bytes();
|
||||
let body = req.collect().await?.to_bytes();
|
||||
Ok(serde_json::from_slice(&body)?)
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user