diff --git a/tower-http/src/compression/body.rs b/tower-http/src/compression/body.rs index 989685c1..259e4a27 100644 --- a/tower-http/src/compression/body.rs +++ b/tower-http/src/compression/body.rs @@ -277,6 +277,14 @@ where http_body::SizeHint::new() } } + + fn is_end_stream(&self) -> bool { + if let BodyInner::Identity { inner } = &self.inner { + inner.is_end_stream() + } else { + false + } + } } #[cfg(feature = "compression-gzip")]