1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-08-20 04:35:38 +02:00

use modern signatures for awc send_* and header methods (#2553)

This commit is contained in:
Rob Ede
2021-12-28 03:22:22 +00:00
committed by GitHub
parent 4616ca8ee6
commit 96a4dc9dec
7 changed files with 52 additions and 162 deletions

View File

@@ -190,7 +190,9 @@ where
let body_new = if is_redirect {
// try to reuse body
match body {
Some(ref bytes) => AnyBody::from(bytes.clone()),
Some(ref bytes) => AnyBody::Bytes {
body: bytes.clone(),
},
// TODO: should this be AnyBody::Empty or AnyBody::None.
_ => AnyBody::empty(),
}