Search code examples
iosfacebookgigya

Gigya doesn't work with Facebook while Google and Yahoo do work


I've already looked at this post http://stackoverflow.com/questions/26734090/gigya-facebook-login-completion-handler-not-called and it doesn't answer my question.

I am using Gigya for social login and I can easily get it to work for google and yahoo providers, however the completionHandler is never called in the code below when I make the call with the facebook provider.

    - (void)socialLoginTapped:(NSString *) socialType {
        [Gigya loginToProvider:socialType parameters:nil over:self completionHandler:^(GSUser *user, NSError *error) {
            if (error != nil) {
                switch(error.code) {
                    case 200001:  // user cancelled
                        return;

                    default:      // process other error here
                        return;
                }
            }

            [self processGigyaUser:user];
        }];
    }

I get the Facebook login screen just fine.

What factors would cause this to happen?

I am using the gigyaLoginDontLeaveApp key with value of YES in my plist to show all the integration logins within the app. It doesn't leave the app. So I don't normally call [Gigya handleDidBecomeActive]. On a whim, I did drop it in but it doesn't change the outcome as expected.


Solution

  • Verify that the FacebookAppID in the app's .plist and what is on Gigya are the same. Also update the URL Scheme.