Skip to content

Commit

Permalink
Add FragmentCollector::into_inner (#79)
Browse files Browse the repository at this point in the history
  • Loading branch information
jembishop authored Jun 20, 2024
1 parent 5384510 commit 4e6b56a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/fragment.rs
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,12 @@ impl<'f, S> FragmentCollector<S> {
self.write_half.write_frame(&mut self.stream, frame).await?;
Ok(())
}

/// Consumes the `FragmentCollector` and returns the underlying stream.
#[inline]
pub fn into_inner(self) -> S {
self.stream
}
}

#[cfg(feature = "unstable-split")]
Expand Down

0 comments on commit 4e6b56a

Please sign in to comment.