From 69bf6a080d4148898ba2e7b1261a312d71c013f3 Mon Sep 17 00:00:00 2001 From: 18alantom <2.alan.tom@gmail.com> Date: Tue, 20 Sep 2022 21:17:43 +0530 Subject: [PATCH] fix: catch more network errors - prevent dupe account names in Catalan --- main/helpers.ts | 2 ++ translations/ca-ES.csv | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/main/helpers.ts b/main/helpers.ts index bb3913ab5..8dfe9351a 100644 --- a/main/helpers.ts +++ b/main/helpers.ts @@ -77,10 +77,12 @@ export function rendererLog(main: Main, ...args: unknown[]) { export function isNetworkError(error: Error) { switch (error?.message) { case 'net::ERR_INTERNET_DISCONNECTED': + case 'net::ERR_NETWORK_CHANGED': case 'net::ERR_PROXY_CONNECTION_FAILED': case 'net::ERR_CONNECTION_RESET': case 'net::ERR_CONNECTION_CLOSE': case 'net::ERR_NAME_NOT_RESOLVED': + case 'net::ERR_TIMED_OUT': case 'net::ERR_CONNECTION_TIMED_OUT': return true; default: diff --git a/translations/ca-ES.csv b/translations/ca-ES.csv index 9714da808..a82a9c569 100644 --- a/translations/ca-ES.csv +++ b/translations/ca-ES.csv @@ -465,7 +465,7 @@ Role,Rol, "Round Off Account","Round Off Account", Salary,Salari, Sales,Vendes, -"Sales Expenses",Vendes, +"Sales Expenses","Despeses de vendes", "Sales Invoice",, "Sales Invoice Item",, "Sales Invoice Settings",,