Fix code style

tungstenite-0.20
Sebastian Dröge 2 years ago
parent b3376f3dd9
commit 04a9a07a7d
  1. 4
      src/lib.rs

@ -388,7 +388,9 @@ where
} }
fn poll_flush(mut self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Result<(), Self::Error>> { fn poll_flush(mut self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Result<(), Self::Error>> {
(*self).with_context(Some((ContextWaker::Write, cx)), |s| cvt(s.flush())).map(|r| { (*self)
.with_context(Some((ContextWaker::Write, cx)), |s| cvt(s.flush()))
.map(|r| {
// WebSocket connection has just been closed. Flushing completed, not an error. // WebSocket connection has just been closed. Flushing completed, not an error.
match r { match r {
Err(WsError::ConnectionClosed) => Ok(()), Err(WsError::ConnectionClosed) => Ok(()),

Loading…
Cancel
Save