Do not kill entire chat window when websocket closes.

Reopens the websocket on close. Prevents badly configured reverse proxies from making the application stop working.
This commit is contained in:
ProjectMoon 2024-07-30 16:03:38 +02:00 committed by GitHub
parent 96f67c7028
commit f03f665e08
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -194,7 +194,7 @@ const useSocket = (
ws.onclose = () => { ws.onclose = () => {
clearTimeout(timeoutId); clearTimeout(timeoutId);
setError(true); setWs(null);
console.log('[DEBUG] closed'); console.log('[DEBUG] closed');
}; };