getUserDataByEmail method
Implementation
Future<Map<String, dynamic>?> getUserDataByEmail(
String email, {
/// this will make sure that the auth data for user exist first before setting the
/// user data
bool authDataMustExist = true,
}) async {
if (authDataMustExist) {
AuthModel? authModel =
await _authService.authDbProvider.getUserByEmail(email);
if (authModel == null) {
throw NoUserRegisteredException();
}
}
return userDataDbProvider.getUserDataByEmail(email);
}