Skip to content

Commit

Permalink
Fix init
Browse files Browse the repository at this point in the history
  • Loading branch information
dnys1 committed Mar 9, 2024
1 parent 5a7c4f9 commit b1a3bcd
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/celest_auth/lib/src/auth_impl.dart
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,11 @@ final class AuthImpl implements Auth {
try {
final user = await protocol.userInfo();
initialState = Authenticated(user);
_authStateController.add(initialState);
} on UnauthorizedException {
initialState = const Unauthenticated();
signOut();
}
_authStateController.add(initialState);
return initialState;
});
}
Expand Down

0 comments on commit b1a3bcd

Please sign in to comment.