Skip to content

Commit

Permalink
fixup! Re-design the StreamMuxer trait
Browse files Browse the repository at this point in the history
Fix test.
  • Loading branch information
thomaseizinger committed Jun 2, 2022
1 parent 4d8dd04 commit 2c940f0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/muxing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ impl<T> StreamMuxerEvent<T> {

/// Map the stream within [`StreamMuxerEvent::InboundSubstream`] and
/// [`StreamMuxerEvent::OutboundSubstream`] to a new type.
pub fn map_stream<O>(self, map: impl FnOnce(O) -> O) -> StreamMuxerEvent<O> {
pub fn map_stream<O>(self, map: impl FnOnce(T) -> O) -> StreamMuxerEvent<O> {
match self {
StreamMuxerEvent::InboundSubstream(stream) => {
StreamMuxerEvent::InboundSubstream(map(stream))
Expand Down

0 comments on commit 2c940f0

Please sign in to comment.