resetPasswordByEmail method

Future<ResponseModel> resetPasswordByEmail(
  1. ResetPasswordByEmailInput body
)

Reset password by email

Implementation

Future<ResponseModel> resetPasswordByEmail(
    ResetPasswordByEmailInput body) async {
  try {
    String url = '$baseUrl/email/reset-password';
    Response? response = await postx(url, body: json.encode(body));
    ResponseModel data =
        ResponseModel.fromJson(json.decode(response.toString()));
    return Future.value(data);
  } catch (e) {
    return Future.error(e);
  }
}