From 3c328ede0aa405dca9a0fc97f7917f6399990705 Mon Sep 17 00:00:00 2001 From: EthanHealy01 Date: Thu, 25 Sep 2025 18:53:25 +0100 Subject: [PATCH] linter --- frontend/src/services/http.ts | 8 -------- 1 file changed, 8 deletions(-) diff --git a/frontend/src/services/http.ts b/frontend/src/services/http.ts index 35a79ca1e..7f8d6bb7b 100644 --- a/frontend/src/services/http.ts +++ b/frontend/src/services/http.ts @@ -50,11 +50,6 @@ function extractAxiosErrorMessage(error: any): { title: string; body: string } { if (typeof raw === 'string') return raw; try { return JSON.stringify(data); } catch { return ''; } })(); - // Specific friendly mapping for encrypted PDFs (centralized toast also fires in interceptor) - if (ENCRYPTION_ERROR_REGEX.test(body)) { - const title = titleForStatus(error.response?.status); - return { title, body: ENCRYPTION_FRIENDLY }; - } const ids = extractIds(); const title = titleForStatus(status); if (ids && ids.length > 0) { @@ -70,9 +65,6 @@ function extractAxiosErrorMessage(error: any): { title: string; body: string } { } try { const msg = (error?.message || String(error)) as string; - if (ENCRYPTION_ERROR_REGEX.test(msg)) { - return { title: 'Request error', body: ENCRYPTION_FRIENDLY }; - } return { title: 'Network error', body: isUnhelpfulMessage(msg) ? FRIENDLY_FALLBACK : msg }; } catch (e) { // ignore extraction errors