Free, Open Source, Self-Hosted WhatsApp API Gateway
TypeScript apibotgatewayself-hostedwhatsappwhatsapp-apiwhatsapp-automationwhatsapp-botwhatsapp-gatewaywhatsapp-gateway-apiwhatsapp-webwhatsapp-web-api
docs(dashboard): say which statuses the connection-lost toast folds
Yudhi Armyndharis42bb769618ef
diff --git a/dashboard/src/services/api.ts b/dashboard/src/services/api.tsindex 1ab6e6e42..6a91daf40 100644--- a/dashboard/src/services/api.ts+++ b/dashboard/src/services/api.ts@@ -720,8 +720,8 @@ export interface SearchResults {// Error carrying the HTTP status and, when the gateway supplied one, its machine code.async function handleErrorResponse<T>(response: Response): Promise<T> {// On a non-JSON body (e.g. a reverse-proxy 502/503/504 HTML page) fall through to `HTTP <status>`- // rather than statusText: the status code is what the toast connection-lost de-dup matches on,- // and statusText is empty over HTTP/2 anyway.+ // rather than statusText: the toast folds an exact `HTTP 502`/`HTTP 503` into its connection-lost+ // toast (a 504 keeps its own), and statusText is empty over HTTP/2 anyway.const error = await response.json().catch(() => ({}));if (isKeyUnusable(response.status, error.message)) {sessionStorage.removeItem('openwa_api_key');