console the message instead of toast when failing to refresh token

This commit is contained in:
秦秋旭 2023-03-02 15:26:32 +08:00
parent e6698287bc
commit f6abf2bc38

View File

@ -43,7 +43,7 @@ const refreshToken = (() => {
refreshingToken?.catch((error) => {
if (error instanceof AxiosError) {
Router.push('/login')
throwError(error)
console.error(error.response?.data.message)
}
})
return refreshingToken