从谷歌注销加上我使用了 disconnect 方法,但之后登录应用程序直接进入权限页面。不要求登录。为什么?
here is my Sign In function
-(google*) MethodgoogleLogin
{
[[NSNotificationCenter defaultCenter] removeObserver:self name"gotGoogleErrorAppClosed" object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selectorselector(gotGoogleErrorAppClosed name"gotGoogleErrorAppClosed" object:nil];
obj_google = [[google alloc]init];
personName=[[GTLPlusPersonName alloc]init];
// google + code
signIn = [GPPSignIn sharedInstance];
signIn.shouldFetchGooglePlusUser = YES;
signIn.shouldFetchGoogleUserID = YES;
signIn.shouldFetchGoogleUserEmail = YES;
signIn.clientID = @"384945330563-pcls0t8c28s1jf7qiod9555sg7edfqhj.apps.googleusercontent.com";
signIn.scopes = @[ kGTLAuthScopePlusLogin ];
signIn.delegate = obj_google;
[signIn authenticate];
return obj_google;
}
这是我的退出功能
-(void)signOut
{
[signIn disconnect];
[signIn signOut];
}
您可以使用 GPPSignIn 对象的 signOut 方法来注销您的用户,例如:
- (void)signOut {
[[GPPSignIn sharedInstance] signOut];
}
然后撤销 token 并断开应用程序。
欲了解更多信息,请访问:- https://developers.google.com/+/mobile/ios/sign-in#sign_out_the_user
关于ios - iOS 中的社交注销 Google Plus 问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25906075/
欢迎光临 OStack程序员社区-中国程序员成长平台 (https://ostack.cn/) | Powered by Discuz! X3.4 |