New error in iOS 5: WebKit discarded an uncaught exception

后端 未结 2 1841
野性不改
野性不改 2021-02-06 09:09

I am trying to load a UIWebView with the Facebook OAuth authorization URL and I am using the following code. When my UIWebView loads with Facebook logi

相关标签:
2条回答
  • 2021-02-06 09:26

    Are you using the Ray Wenderlich code? (FBFunLoginDialog).. I found that this fixes it:

    -(void)checkLoginRequired:(NSString *)urlString {
        NSLog(@"Url: %@",urlString);
        if ([urlString rangeOfString:@"login.php"].location != NSNotFound && [urlString rangeOfString:@"refid"].location == NSNotFound) {
                [_delegate displayRequired];
        } else if ([urlString rangeOfString:@"user_denied"].location != NSNotFound) {
             [_delegate closeTapped];
        }
    }
    
    0 讨论(0)
  • 2021-02-06 09:46

    I have the same problem. I try to present view controller just after dismissing.

    [self dismissModalViewControllerAnimated:YES];
    

    When I try to do it without animation it works perfectly. use dismissViewControllerAnimated:completion:

    0 讨论(0)
提交回复
热议问题