TF-644 Remove 401 error when refreshToken
This commit is contained in:
@@ -77,7 +77,8 @@ class AuthorizationInterceptors extends InterceptorsWrapper {
|
|||||||
void onError(DioError err, ErrorInterceptorHandler handler) async {
|
void onError(DioError err, ErrorInterceptorHandler handler) async {
|
||||||
final requestOptions = err.requestOptions;
|
final requestOptions = err.requestOptions;
|
||||||
log('AuthorizationInterceptors::onError(): $err');
|
log('AuthorizationInterceptors::onError(): $err');
|
||||||
if ((_isTokenExpired() || err.response?.statusCode == 401) &&
|
if (_isTokenExpired() &&
|
||||||
|
err.response?.statusCode == 401 &&
|
||||||
_isAuthenticationOidcValid()) {
|
_isAuthenticationOidcValid()) {
|
||||||
try {
|
try {
|
||||||
final newToken = await _authenticationClient.refreshingTokensOIDC(
|
final newToken = await _authenticationClient.refreshingTokensOIDC(
|
||||||
|
|||||||
Reference in New Issue
Block a user