ios - Parse.com and Facebook login, runs infinite loop -
i updated both parse , facebook ios sdks latest versions, , when try login using facebook app crashes, , debugger can see calling 3-4 methods in endless loop.
my login code looks this:
- (void)opensession { uiviewcontroller *topviewcontroller = self.window.rootviewcontroller; nsarray *permissions = [nsarray arraywithobjects:@"user_likes", @"friends_likes", nil]; // login pfuser using facebook [pffacebookutils loginwithpermissions:permissions block:^(pfuser *user, nserror *error) { if (!user) { if (!error) { nslog(@"uh oh. user cancelled facebook login."); } else { nslog(@"uh oh. error occurred: %@", error); } } else if (user.isnew) { nslog(@"user facebook signed , logged in!"); if ([[topviewcontroller presentedviewcontroller] iskindofclass:[paloginviewcontroller class]]) { [topviewcontroller dismissviewcontrolleranimated:yes completion:nil]; } } else { nslog(@"user facebook logged in!"); if ([[topviewcontroller presentedviewcontroller] iskindofclass:[paloginviewcontroller class]]) { [topviewcontroller dismissviewcontrolleranimated:yes completion:nil]; } } }]; }
the error occurs when loginwithpermissions
called. crashes xcode , debugger showing awful lot of calls fb login methods - thousands actually:
what wrong?
this issue reported bug on facebook: https://developers.facebook.com/bugs/188127071335876?browse=search_5176d24c698df3761093726
it has been fixed, , can confirm logging in works - sandbox enabled.
Comments
Post a Comment