resetPasswordByPhoneCode static method

Future<AuthResult> resetPasswordByPhoneCode(
  1. String phone,
  2. String code,
  3. String password
)

reset password by phone number and an SMS code.

Implementation

static Future<AuthResult> resetPasswordByPhoneCode(
    String phone, String code, String password) async {
  var body = jsonEncode(
      {'phone': phone, 'code': code, 'newPassword': Util.encrypt(password)});
  final Result result = await post('/api/v2/password/reset/sms', body);
  return AuthResult(result);
}