api-macros: Fix a typo
This commit is contained in:
parent
e7a31f1fd1
commit
15433a9751
@ -29,8 +29,8 @@ impl Response {
|
|||||||
if #bytes::Buf::has_remaining(&body) {
|
if #bytes::Buf::has_remaining(&body) {
|
||||||
#serde_json::from_reader(#bytes::Buf::reader(body))?
|
#serde_json::from_reader(#bytes::Buf::reader(body))?
|
||||||
} else {
|
} else {
|
||||||
// If the reponse body is completely empty, pretend it is an empty JSON
|
// If the response body is completely empty, pretend it is an empty
|
||||||
// object instead. This allows responses with only optional body
|
// JSON object instead. This allows responses with only optional body
|
||||||
// parameters to be deserialized in that case.
|
// parameters to be deserialized in that case.
|
||||||
#serde_json::from_str("{}")?
|
#serde_json::from_str("{}")?
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user