[auth][android] attempt to get verificationId from writeToParcel
This commit is contained in:
parent
d3ea57f76d
commit
fe74c36e5b
|
@ -746,15 +746,13 @@ class RNFirebaseAuth extends ReactContextBaseJavaModule {
|
||||||
public void onVerificationCompleted(final PhoneAuthCredential phoneAuthCredential) {
|
public void onVerificationCompleted(final PhoneAuthCredential phoneAuthCredential) {
|
||||||
Log.d(TAG, "verifyPhoneNumber:verification:onVerificationCompleted");
|
Log.d(TAG, "verifyPhoneNumber:verification:onVerificationCompleted");
|
||||||
WritableMap state = Arguments.createMap();
|
WritableMap state = Arguments.createMap();
|
||||||
Parcel p1 = Parcel.obtain();
|
|
||||||
|
|
||||||
phoneAuthCredential.writeToParcel(p1, 0);
|
Parcel parcel = Parcel.obtain();
|
||||||
String verificationId = p1.readString();
|
phoneAuthCredential.writeToParcel(parcel, 0);
|
||||||
String smsCode = p1.readString();
|
// TODO Read values - to get verification id
|
||||||
|
parcel.recycle();
|
||||||
p1.recycle();
|
state.putString("code", phoneAuthCredential.getSmsCode());
|
||||||
state.putString("code", smsCode);
|
state.putString("verificationId", "");
|
||||||
state.putString("verificationId", verificationId);
|
|
||||||
sendPhoneStateEvent(appName, requestKey, "onVerificationComplete", state);
|
sendPhoneStateEvent(appName, requestKey, "onVerificationComplete", state);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue