Skip to content

Commit

Permalink
Fix close implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
fwcd committed Jul 17, 2024
1 parent 3cd3c2b commit 87d7b14
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lighthouse-client/src/lighthouse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ impl<S> Lighthouse<S>
/// Closes the WebSocket connection gracefully with a close message. While
/// the server will usually also handle abruptly closed connections
/// properly, it is recommended to always close the [``Lighthouse``].
pub async fn close(&self) -> Result<()> {
Ok(self.ws_sink.lock().await.close().await?)
pub async fn close(&mut self) -> Result<()> {
Ok(self.ws_sink.close().await?)
}
}

0 comments on commit 87d7b14

Please sign in to comment.