public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { base.OnCodeSent(verificationId, forceResendingToken); VerificationId = verificationId; ResendingToken = forceResendingToken; CodeSent?.Invoke(this, new PhoneAuthCodeSentEventArgs(verificationId)); }
public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { // The SMS verification code has been sent to the provided phone number, we // now need to ask the user to enter the code and then construct a credential // by combining the code with a verification ID. base.OnCodeSent(verificationId, forceResendingToken); }
public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken token) { base.OnCodeSent(verificationId, token); _authManager.VerificationId = verificationId; _authManager.ResendToken = token; _authManager.SetVerificationStatus(VerificationStatus.CodeSent); }
public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { var result = new PhoneNumberVerificationResult { VerificationId = verificationId }; _tcs.SetResult(result); }
public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { var result = new PhoneNumberVerificationResult { VerificationId = verificationId }; _subject.OnNext(result); _subject.OnCompleted(); }
public void ResendVerificationCode(string phoneNumber, PhoneAuthProvider.ForceResendingToken token) { PhoneAuthProvider.GetInstance(Auth).VerifyPhoneNumber( phoneNumber, 60, TimeUnit.Seconds, Activity, MCallbacks, token); }
public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { // The SMS verification code has been sent to the provided phone number, we // now need to ask the user to enter the code and then construct a credential // by combining the code with a verification ID. base.OnCodeSent(verificationId, forceResendingToken); IsCodeSent = true; VerificationId = verificationId; this._token = forceResendingToken; CodeSent?.Invoke(this, new EventArgs()); }
public Task <VerifyNumberResult> ResendVerificationCode(string phoneNumber) { var tcs = new TaskCompletionSource <VerifyNumberResult>(); PhoneAuthProvider.Instance.VerifyPhoneNumber(phoneNumber, 60, TimeUnit.Seconds, _currentActivity.Activity, new VerificationCallback( credential => { }, exception => tcs.SetException(exception), (verificationId, forceResendingToken) => { _forceResendToken = forceResendingToken; tcs.SetResult(new VerifyNumberResult { VerificationId = verificationId }); }), _forceResendToken); return(tcs.Task); }
public override void OnCodeSent(string p0, PhoneAuthProvider.ForceResendingToken p1) { // The SMS verification code has been sent to the provided phone number, we // now need to ask the user to enter the code and then construct a credential // by combining the code with a verification ID. Log.Debug(TAG, "onCodeSent:$verificationId"); // Save verification ID and resending token so we can use them later storedVerificationId = p0; resendToken = p1; onCodeSent?.Invoke(storedVerificationId, resendToken); // [START_EXCLUDE] // Update UI //updateUI(STATE_CODE_SENT); // [END_EXCLUDE] }
public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { base.OnCodeSent(verificationId, forceResendingToken); // The SMS verification code has been sent to the provided phone number, we // now need to ask the user to enter the code and then construct a credential // by combining the code with a verification ID. // Notify user !! // Save verification ID and resending token so we can use them later mVerificationId = verificationId; mResendToken = forceResendingToken; UpdateInfo("SENT"); }
public override void OnCodeSent(string p0, PhoneAuthProvider.ForceResendingToken p1) { base.OnCodeSent(p0, p1); // Save verification ID for future use App.LocalDataService.SaveValue(nameof(LocalDataKeys.FirebaseAuthVerificationId), p0); if (WhiteListedPhoneNo != null) { var response = SignIn(FirebaseServiceCallBack, p0, WhiteListedPhoneNo.Code).Result; if (!response.Success) { FirebaseServiceCallBack?.OnVerificationFailed(response.ErrorMessage); } } else { FirebaseServiceCallBack?.OnCodeSent(p0); } }
public override async void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { _tvStatus.Text = "Sms code received. Now linking..."; var credential = PhoneAuthProvider.GetCredential(verificationId, MainActivity.SmsCode); IAuthResult result = null; try { result = await FirebaseAuth.Instance.CurrentUser.LinkWithCredentialAsync(credential); } catch (FirebaseAuthException ex) { _tvStatus.Text = ex.Message; _btnLinkPhone.Enabled = true; return; } _tvStatus.Text = "Account link successful."; _btnLinkPhone.Visibility = ViewStates.Gone; _btnSigninAnonymous.Visibility = ViewStates.Visible; _btnSigninAnonymous.Enabled = true; }
public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { base.OnCodeSent(verificationId, forceResendingToken); _tcs.TrySetResult(new PhoneNumberVerificationResult(null, verificationId)); }
private void OnCodeSent(string storedVerificationId, PhoneAuthProvider.ForceResendingToken resendToken) { ViewModel.IsOTPSent = true; verificationId = storedVerificationId; }
public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { base.OnCodeSent(verificationId, forceResendingToken); _onSent(verificationId, forceResendingToken); }
public override void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { base.OnCodeSent(verificationId, forceResendingToken); _verificationId = verificationId; _phoneAuthTcs?.TrySetResult(true); }
public void OnCodeSent(string verificationId, PhoneAuthProvider.ForceResendingToken forceResendingToken) { Toast.MakeText(Context.ApplicationContext, "Sent", ToastLength.Long).Show(); _verificationId = verificationId; _resendCodeTxtView.Enabled = false; }