pub fn into_stream(self) -> impl Stream<Item = reqwest::Result<Bytes>> {
        stream::unfold((self, false), |(mut blob, has_errored)| {
            async move {
                if has_errored {
                    return None;
                }
                match blob.chunk().await {
                    Ok(Some(val)) => Some((Ok(val), (blob, false))),
                    Ok(None) => None,
                    Err(e) => Some((Err(e), (blob, true))),
                }
            }
        })
    }
/// Consumes self, returning a Stream of Bytes.
Consumes self, returning a Stream of Bytes.
Consumes self returning a Stream of Bytes .
pub fn into_stream(self) -> impl Stream<Item = reqwest::Result<Bytes>> {
        stream::unfold((self, false), |(mut blob, has_errored)| {
            async move {
                if has_errored {
                    return None;
                }
                match blob.chunk().await {
                    Ok(Some(val)) => Some((Ok(val), (blob, false))),
                    Ok(None) => None,
                    Err(e) => Some((Err(e), (blob, true))),
                }
            }
        })
    }
pub fn into_stream ( self ) -> impl Stream < Item = reqwest :: Result < Bytes > > { stream :: unfold ( ( self , false ) , | ( mut blob , has_errored ) | { async move { if has_errored { return None ; } match blob . chunk ( ) . await { Ok ( Some ( val ) ) => Some ( ( Ok ( val ) , ( blob , false ) ) ) , Ok ( None ) => None , Err ( e ) => Some ( ( Err ( e ) , ( blob , true ) ) ) , } } } ) }
Consumes self, returning a Stream of Bytes.
Consumes self returning a Stream of Bytes .
self
self