Im trying to allow users to sign up with my app using facebook and Amazon Cognito. I found previous documentation saying to use:
let token = FBSDKAccessToken.currentAccessToken().tokenString
var logins: NSDictionary = NSDictionary(dictionary: ["graph.facebook.com" : token])
credentialsProvider.logins = [AWSIdentityProviderFacebook: token]
but I am getting the message that logins is deprecated and to use the protocol AWSIdentityProviderManager to provide logins to the credentials provider, which I don't know how to do.
I tried to have my class implement AWSIdentityProviderManager and created a logins method, since I notice credentialsProvider has a method "setIdentiyProviderManagerOnce(self)", but I didnt know what to do in the implemented logins() method to hookup the facebook token to the credentials manager.
Ive looked at Amazons github examples but I they didnt seem to help much
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…