0
我正在嘗試使用此代碼登錄Firebase以生成Firebase身份驗證憑據。Facebook身份驗證令牌未能創建Firebase身份驗證
func signIn(fromViewController controller: UIViewController) -> Promise<AuthCredential> {
return wrap { completion in
self.loginManager.logIn(withReadPermissions: ["public_profile"],
from: controller,
handler:completion)
}
.then { result -> AuthCredential in
if result.isCancelled {
throw NSError.cancelledError()
}
let token = result.token!
return FacebookAuthProvider.credential(withAccessToken:token.tokenString)
}
}
並獲取此錯誤。
ERROR Error Domain=FIRAuthErrorDomain Code=17999 "An internal error has occurred, print and inspect the error details for more information." UserInfo={error_name=ERROR_INTERNAL_ERROR, NSLocalizedDescription=An internal error has occurred, print and inspect the error details for more information., NSUnderlyingError=0x6040001cb050 {Error Domain=FIRAuthInternalErrorDomain Code=3 "(null)" UserInfo={FIRAuthErrorUserInfoDeserializedResponseKey={
code = 400;
errors = (
{
domain = global;
message = "Unsuccessful debug_token response from Facebook: {\"error\":{\"message\":\"(#100) You must provide an app access token or a user access token that is an owner or developer of the app\",\"type\":\"OAuthException\",\"code\":100,\"fbtrace_id\":\"CCGlFkNF1pl\"}}";
reason = invalid;
}
);
message = "Unsuccessful debug_token response from Facebook: {\"error\":{\"message\":\"(#100) You must provide an app access token or a user access token that is an owner or developer of the app\",\"type\":\"OAuthException\",\"code\":100,\"fbtrace_id\":\"CCGlFkNF1pl\"}}";
}}}}
設置我在Facebook開發應用領域和剪切和粘貼應用程序ID和祕密密鑰進入火力Facebook的身份驗證設置。所以我現在很擔心我可能做錯了什麼。
任何人都遇到過這個問題?
你的先生,是一個鋼鐵般的眼睛碼騎師!這解決了它。 – drekka
沒問題,我們很樂意提供幫助。 – aofdev