mirror of
https://github.com/immich-app/immich.git
synced 2024-11-24 08:52:28 +02:00
fix(mobile): long waiting time for login request when server is unreachable (#12100)
* fix(mobile): long waiting time for login request when server is unreachable * lint * increase timeout duration
This commit is contained in:
parent
74f18a4523
commit
9bfaa525db
@ -170,8 +170,10 @@ class AuthenticationNotifier extends StateNotifier<AuthenticationState> {
|
||||
UserPreferencesResponseDto? userPreferences;
|
||||
try {
|
||||
final responses = await Future.wait([
|
||||
_apiService.usersApi.getMyUser(),
|
||||
_apiService.usersApi.getMyPreferences(),
|
||||
_apiService.usersApi.getMyUser().timeout(const Duration(seconds: 7)),
|
||||
_apiService.usersApi
|
||||
.getMyPreferences()
|
||||
.timeout(const Duration(seconds: 7)),
|
||||
]);
|
||||
userResponse = responses[0] as UserAdminResponseDto;
|
||||
userPreferences = responses[1] as UserPreferencesResponseDto;
|
||||
|
Loading…
Reference in New Issue
Block a user