Skip to content

Commit

Permalink
fix(multipart): always stream body
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasfernog authored and sbstp committed Apr 22, 2022
1 parent c715941 commit 7179914
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/multipart.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,10 +96,7 @@ pub struct Multipart<'data> {

impl Body for Multipart<'_> {
fn kind(&mut self) -> IoResult<BodyKind> {
match self.data.content_len() {
Some(len) => Ok(BodyKind::KnownLength(len)),
None => Ok(BodyKind::Chunked),
}
Ok(BodyKind::Chunked)
}

fn write<W: Write>(&mut self, mut writer: W) -> IoResult<()> {
Expand Down

0 comments on commit 7179914

Please sign in to comment.