diff --git a/packages/backend/src/helpers/http-client/index.ts b/packages/backend/src/helpers/http-client/index.ts index 79a7009c..4752121a 100644 --- a/packages/backend/src/helpers/http-client/index.ts +++ b/packages/backend/src/helpers/http-client/index.ts @@ -44,7 +44,8 @@ export default function createHttpClient({ const { status } = error.response; if ( - status === 401 && + // TODO: provide a `shouldRefreshToken` function in the app + (status === 401 || status === 403) && $.app.auth.refreshToken && !$.app.auth.isRefreshTokenRequested ) {