feat: don't rethrow same error and handle errors globally

This commit is contained in:
Dominik Pschenitschni 2021-10-09 16:04:19 +02:00
parent 6f51921588
commit 3b940cb56c
No known key found for this signature in database
GPG key ID: B257AC0149F43A77
71 changed files with 69 additions and 451 deletions

View file

@ -53,9 +53,7 @@ export const refreshToken = (persist: boolean): Promise<AxiosResponse> => {
return Promise.resolve(r)
})
.catch(e => {
// eslint-disable-next-line
console.log('Error renewing token: ', e)
return Promise.reject(e)
throw new Error('Error renewing token: ', { cause: e })
})
}