linkAndRetrieveData在iOS中无法使用Facebook进行Firebase身份验证

问题描述 投票:-1回答:1

首先我打电话 -

FBSDKLoginManager().logIn(withReadPermissions: ["public_profile", "email"], from: self)

成功获得证书 -

let credential = FacebookAuthProvider.credential(withAccessToken: FBSDKAccessToken.current().tokenString)

然后将凭证传递给linkAndRetrieveData -

Auth.auth().currentUser?.linkAndRetrieveData(with: credential)

收到此错误,上面写着“MISSING_ID_TOKEN” -

{
    FIRAuthErrorUserInfoNameKey = "ERROR_INTERNAL_ERROR";
    NSLocalizedDescription = "An internal error has occurred, print and inspect the error details for more information.";
    NSUnderlyingError = "Error Domain=FIRAuthInternalErrorDomain Code=3 \"(null)\" UserInfo={FIRAuthErrorUserInfoDeserializedResponseKey={\n    code = 400;\n    message = \"MISSING_ID_TOKEN\";\n    status = \"INVALID_ARGUMENT\";\n}}";
    "error_name" = "ERROR_INTERNAL_ERROR";
}

它适用于 -

Auth.auth().signInAndRetrieveData

我在这做错了什么?

ios swift firebase firebase-authentication facebook-authentication
1个回答
3
投票

应该很快就可以使用Firebase身份验证版本5.4.1进行修复。请参阅以下问题:

https://github.com/firebase/firebase-ios-sdk/issues/2522

© www.soinside.com 2019 - 2024. All rights reserved.