authenticate method

  1. @override
Future<Response> authenticate(
  1. String email,
  2. String password
)
override

Authenticates an user in the service using email and password

Implementation

@override
Future<Response> authenticate(String email, String password) {
  if (email.isEmpty || password.isEmpty || !EmailValidator.validate(email)) {
    throw Exception(
        'The arguments must be not empty and the e-mail must be valid');
  } else {
    return _service.authenticate(email, password);
  }
}