We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 491a6fc commit a0c8cd2Copy full SHA for a0c8cd2
lighthouse-client/src/lighthouse.rs
@@ -303,7 +303,7 @@ impl<S> Lighthouse<S>
303
/// Closes the WebSocket connection gracefully with a close message. While
304
/// the server will usually also handle abruptly closed connections
305
/// properly, it is recommended to always close the [``Lighthouse``].
306
- pub async fn close(&mut self) -> Result<()> {
307
- Ok(self.ws_sink.close().await?)
+ pub async fn close(&self) -> Result<()> {
+ Ok(self.ws_sink.lock().await.close().await?)
308
}
309
0 commit comments