chore(dependencies): update to http-body 0.3

This commit is contained in:
Sean McArthur
2019-12-04 16:29:58 -08:00
parent 4d7a2266b8
commit a738d03fd3
5 changed files with 11 additions and 12 deletions

View File

@@ -319,7 +319,7 @@ impl Opts {
async {
let res = fut.await.expect("client wait");
let mut body = res.into_body();
while let Some(_chunk) = body.next().await {}
while let Some(_chunk) = body.data().await {}
}
};
@@ -356,7 +356,7 @@ fn spawn_server(rt: &mut tokio::runtime::Runtime, opts: &Opts) -> SocketAddr {
.serve(make_service_fn( move |_| async move {
Ok::<_, hyper::Error>(service_fn(move |req: Request<Body>| async move {
let mut req_body = req.into_body();
while let Some(_chunk) = req_body.next().await {}
while let Some(_chunk) = req_body.data().await {}
Ok::<_, hyper::Error>(Response::new(Body::from(body)))
}))
}))