Mute websocket errors

This commit is contained in:
Dominic Zimmer 2022-10-28 16:41:01 +02:00
parent 668b40d5dd
commit 69efe9ee28

View File

@ -17,7 +17,11 @@ const Client = () => {
// Send data to server
useEffect(() => {
if (!socket) return;
socket.send(JSON.stringify(buttonMap));
try {
socket.send(JSON.stringify(buttonMap));
} catch (err: unknown) {
}
}, [buttonMap, socket]);
useEffect(() => {