From 3609b9a848c56ea0d014e4de1a009fc9cc8d5734 Mon Sep 17 00:00:00 2001 From: Nickiel12 <35903114+Nickiel12@users.noreply.github.com> Date: Wed, 27 Mar 2024 17:06:13 -0700 Subject: [PATCH] removed unwraps on close socket --- src/joystick_loop.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/joystick_loop.rs b/src/joystick_loop.rs index 97f2f05..fe0e2db 100644 --- a/src/joystick_loop.rs +++ b/src/joystick_loop.rs @@ -30,8 +30,8 @@ impl SocketState { fn close_websocket(&mut self) { if let Some(ref mut x) = self.socket { info!("closing websocket"); - x.send_message(&Message::close()).unwrap(); - x.shutdown().unwrap(); + let _ = x.send_message(&Message::close()); + let _ = x.shutdown(); self.socket = None; } }