1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-09-01 01:16:59 +02:00

re-export rt in web and add main macro (#1575)

This commit is contained in:
Rob Ede
2020-06-22 20:09:48 +01:00
committed by GitHub
parent c11052f826
commit a70e599ff5
18 changed files with 71 additions and 29 deletions

View File

@@ -315,6 +315,7 @@ pub struct HttpMessageBody {
impl HttpMessageBody {
/// Create `MessageBody` for request.
#[allow(clippy::borrow_interior_mutable_const)]
pub fn new(req: &HttpRequest, payload: &mut dev::Payload) -> HttpMessageBody {
let mut len = None;
if let Some(l) = req.headers().get(&header::CONTENT_LENGTH) {