fix(workspace): normalize websocket headers for reverse proxies and show detailed disconnect reason
MindSift CI & Docker Release / Build, Test in Container & Push (push) Successful in 1m4s
MindSift CI & Docker Release / Build, Test in Container & Push (push) Successful in 1m4s
This commit is contained in:
1 parent
c2ed76c6a4
commit
155d2daa02
3 files changed
+49
-7
No files matched your search
@@ -1118,8 +1118,9 @@ export function connectWebSocket(): void {
|
||||
}
|
||||
};
|
||||
|
||||
ws.onclose = () => {
|
||||
ws.onclose = (evt: CloseEvent) => {
|
||||
activeGlobalWS = null;
|
||||
console.warn('[MindSift Global WS] Closed with code:', evt?.code, 'reason:', evt?.reason);
|
||||
notifyStatusChange(false);
|
||||
if (!manualDisconnect && getToken()) {
|
||||
clearTimeout(wsReconnectTimer);
|
||||
@@ -1131,7 +1132,8 @@ export function connectWebSocket(): void {
|
||||
}
|
||||
};
|
||||
|
||||
ws.onerror = () => {
|
||||
ws.onerror = (e) => {
|
||||
console.warn('[MindSift Global WS] Error:', e);
|
||||
notifyStatusChange(false);
|
||||
try {
|
||||
ws.close();
|
||||
|
||||
Reference in new issue
Block a user