Skip to content

Commit a0bcf62

Browse files
author
Devdutt Shenoi
committed
fix: enable sync only for builds without websocket support
1 parent d3ebb51 commit a0bcf62

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

rumqttc/src/framed.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,5 +92,11 @@ impl Network {
9292
}
9393
}
9494

95+
#[cfg(not(feature = "websocket"))]
9596
pub trait AsyncReadWrite: AsyncRead + AsyncWrite + Send + Sync + Unpin {}
97+
#[cfg(not(feature = "websocket"))]
9698
impl<T> AsyncReadWrite for T where T: AsyncRead + AsyncWrite + Send + Sync + Unpin {}
99+
#[cfg(feature = "websocket")]
100+
pub trait AsyncReadWrite: AsyncRead + AsyncWrite + Send + Unpin {}
101+
#[cfg(feature = "websocket")]
102+
impl<T> AsyncReadWrite for T where T: AsyncRead + AsyncWrite + Send + Unpin {}

0 commit comments

Comments
 (0)