From b6705fbbaa79efdeee444b65e1a9af1ed89ae25f Mon Sep 17 00:00:00 2001 From: Paul Frazee Date: Tue, 15 Nov 2022 12:54:04 -0600 Subject: [PATCH] Improve connectivity-issue error message --- src/view/lib/strings.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/view/lib/strings.ts b/src/view/lib/strings.ts index e47863d5..214bb51d 100644 --- a/src/view/lib/strings.ts +++ b/src/view/lib/strings.ts @@ -98,6 +98,9 @@ export function enforceLen(str: string, len: number): string { } export function cleanError(str: string): string { + if (str.includes('Network request failed')) { + return 'Unable to connect. Please check your internet connection and try again.' + } if (str.startsWith('Error: ')) { return str.slice('Error: '.length) }