logInWithEmailAndPassword method
Signs in with the provided email
and password
.
Throws a LogInWithEmailAndPasswordFailure if an exception occurs.
Implementation
Future<void> logInWithEmailAndPassword({
required String email,
required String password,
}) async {
try {
await _firebaseAuth.signInWithEmailAndPassword(
email: email,
password: password,
);
} on FirebaseAuthException catch (e) {
throw LogInWithEmailAndPasswordFailure.fromCode(e.code);
} catch (_) {
throw const LogInWithEmailAndPasswordFailure();
}
}