|
@@ -92,18 +92,18 @@ class U {
|
|
|
}
|
|
|
|
|
|
static Future<Token?> refreshAuth(RefreshTokenBody refreshTokenBody) async {
|
|
|
- print("refresh token");
|
|
|
+ // print("refresh token");
|
|
|
return _lockAuth.synchronized(() async {
|
|
|
- print("refresh token start");
|
|
|
+ // print("refresh token start");
|
|
|
var nw = DateTime.now().millisecondsSinceEpoch;
|
|
|
if (_authLastMs == 0 || nw - _authLastMs >= 5000) {
|
|
|
- print("refresh token request");
|
|
|
+ // print("refresh token request");
|
|
|
ApiAuthRepository apiAuthRepository = ApiAuthRepository();
|
|
|
var token = await _tryRefreshAuth(refreshTokenBody);
|
|
|
_authLastMs = DateTime.now().millisecondsSinceEpoch;
|
|
|
_lastReqToken = token;
|
|
|
}
|
|
|
- print("refresh token finish");
|
|
|
+ // print("refresh token finish");
|
|
|
return _lastReqToken;
|
|
|
});
|
|
|
|