diff --git a/src/toast.tsx b/src/toast.tsx index 3011a9b87..ee2e4d6ae 100644 --- a/src/toast.tsx +++ b/src/toast.tsx @@ -57,9 +57,13 @@ async function showAlertForError(networkError: HTTPError): Promise { return; } - const data = await response.error(); - if (data) { - return error(data.error); + try { + const data = await response.error(); + if (data) { + return error(data.error); + } + } catch { + // fallthrough } const message = httpErrorMessages.find((httpError) => httpError.code === status)?.description;