Block requests until successful login
This commit is contained in:
@@ -112,6 +112,8 @@ export class AuthManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static shouldQueueRequests(): boolean {
|
static shouldQueueRequests(): boolean {
|
||||||
return !AuthManager.isAuthInitialized() || AuthManager.isRefreshingToken();
|
const isLoginRequired = AuthManager.isAuthRequired() === true && AuthManager.getAccessToken() === null;
|
||||||
|
|
||||||
|
return !AuthManager.isAuthInitialized() || AuthManager.isRefreshingToken() || isLoginRequired;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user