diff --git a/src/httpClient.js b/src/httpClient.js index 2ad8f7e..4fc550b 100644 --- a/src/httpClient.js +++ b/src/httpClient.js @@ -11,13 +11,7 @@ const errorMessages = new Set([ ]); function isNetworkError(error) { - const isValid = error && error.name === 'TypeError' && typeof error.message === 'string'; - - if (!isValid) { - return false; - } - - return errorMessages.has(error.message); + return error && error.message && errorMessages.has(error.message); } async function retryExecutor(func) {