signInWithCustomToken method
Tries to sign in a user with a given Custom Token token
.
If successful, it also signs the user in into the app and updates
the onAuthStateChanged
stream.
Use this method after you retrieve a Firebase Auth Custom Token from your server.
If the user identified by the uid
specified in the token doesn't
have an account already, one will be created automatically.
Read how to use Custom Token authentication and the cases where it is useful in the guides.
Implementation
@override
Future<UserCredentialPlatform> signInWithCustomToken(String token) async {
try {
return UserCredential(
this,
await _delegate!.signInWithCustomToken(token),
);
} catch (e) {
throw getFirebaseAuthException(e);
}
}