chore: enable polling to the socket.io on the passenger clients

This commit is contained in:
Nathnael
2026-07-08 06:50:44 +00:00
parent 972b1e973a
commit 15b8068b9e
2 changed files with 6 additions and 2 deletions

View File

@@ -37,7 +37,9 @@ export function useSupportSocket(
`${SOCKET_ORIGIN}/${Passenger.PASSENGER_SUPPORT_WS_NAMESPACE}`,
{
auth: { token },
transports: ['websocket'],
// Prefer WebSocket, fall back to HTTP long-polling if the proxy blocks
// the upgrade (polling rides normal HTTPS, already CSP-allowed).
transports: ['websocket', 'polling'],
withCredentials: true,
},
);

View File

@@ -26,7 +26,9 @@ export function useSupportSocket(enabled: boolean) {
`${SOCKET_ORIGIN}/${Passenger.PASSENGER_SUPPORT_WS_NAMESPACE}`,
{
auth: { guestId: getDeviceId() },
transports: ['websocket'],
// Prefer WebSocket, fall back to HTTP long-polling if the proxy blocks
// the upgrade (polling rides normal HTTPS, already CSP-allowed).
transports: ['websocket', 'polling'],
withCredentials: true,
},
);