feat(body): rename Entity to Payload

Closes #1464
This commit is contained in:
Sean McArthur
2018-04-10 15:55:13 -07:00
parent 313f82d971
commit dfdca25c00
18 changed files with 105 additions and 160 deletions

View File

@@ -32,7 +32,7 @@ impl Service for ParamExample {
Box::new(futures::future::ok(Response::new(INDEX.into())))
},
(&Method::POST, "/post") => {
Box::new(req.into_parts().1.into_stream().concat2().map(|b| {
Box::new(req.into_body().concat2().map(|b| {
// Parse the request body. form_urlencoded::parse
// always succeeds, but in general parsing may
// fail (for example, an invalid post of json), so