mirror of
https://github.com/actix/actix-web.git
synced 2024-11-23 01:51:11 +00:00
passthrough StreamLog error type
This commit is contained in:
parent
3c0d059d92
commit
a2467718ac
1 changed files with 4 additions and 7 deletions
|
@ -322,13 +322,10 @@ pin_project! {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<B> MessageBody for StreamLog<B>
|
impl<B: MessageBody> MessageBody for StreamLog<B> {
|
||||||
where
|
type Error = B::Error;
|
||||||
B: MessageBody,
|
|
||||||
B::Error: Into<Error>,
|
|
||||||
{
|
|
||||||
type Error = Error;
|
|
||||||
|
|
||||||
|
#[inline]
|
||||||
fn size(&self) -> BodySize {
|
fn size(&self) -> BodySize {
|
||||||
self.body.size()
|
self.body.size()
|
||||||
}
|
}
|
||||||
|
@ -344,7 +341,7 @@ where
|
||||||
*this.size += chunk.len();
|
*this.size += chunk.len();
|
||||||
Poll::Ready(Some(Ok(chunk)))
|
Poll::Ready(Some(Ok(chunk)))
|
||||||
}
|
}
|
||||||
Some(Err(err)) => Poll::Ready(Some(Err(err.into()))),
|
Some(Err(err)) => Poll::Ready(Some(Err(err))),
|
||||||
None => Poll::Ready(None),
|
None => Poll::Ready(None),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue