Better form and remove squares
All checks were successful
ci/woodpecker/push/build Pipeline was successful

Signed-off-by: Nikolai Rodionov <allanger@posteo.de>
This commit is contained in:
Nikolai Rodionov
2026-05-28 23:58:08 +02:00
parent aeb5269fc5
commit 84d65786bf
9 changed files with 215 additions and 122 deletions

View File

@@ -63,9 +63,13 @@ class AuthorizationController extends AsyncNotifier<AuthState> {
final accountsGrpc = ref.read(publicAccountsGrpcProvider);
final tokenCtrl = ref.read(tokensControllerProvider.notifier);
final response = await accountsGrpc.signIn(form.toProto());
await tokenCtrl.writeTokenPair(Tokens.fromProto(response.tokenPair));
return state.value!.copyWith(isAuthorized: true);
try {
final response = await accountsGrpc.signIn(form.toProto());
await tokenCtrl.writeTokenPair(Tokens.fromProto(response.tokenPair));
return state.value!.copyWith(isAuthorized: true);
} catch (e) {
rethrow;
}
});
}