0

I was using longInWithFacebook in my app, created few months back,

Now I needed to change it with another facebook app id, I created a new app on facebook.

Now with this new app, only name & fb id is returned and email is missing.

I am using

FBLoginView

I am having this issue since couple of weeks ago. Looks like fb have changed the things recently

It is showing that email is approved item

zaheer
  • 893
  • 13
  • 27
  • @Dharmesh This issue is being produced with new created apps on https://developers.facebook.com , It is working good with apps created few months back – zaheer Jul 30 '15 at 12:08

3 Answers3

1

Facebook have indeed changed things. You no longer get access to a user's email by default, you have to request permission explicitly (and your app probably needs to go through a Facebook review process as well).

damian
  • 3,604
  • 1
  • 27
  • 46
  • Thanks @damian, please guide me where can I request this permission. – zaheer Jul 30 '15 at 12:05
  • 1
    You don't have to go through review for the standard permissions, see https://developers.facebook.com/docs/facebook-login/review/what-is-login-review – Tobi Jul 30 '15 at 12:10
1

Have a look at my answer to a similar question:

Baseline is that you have to request each field which you want returned explicitly. This was a change with the introdcution of the Graph API v2.4.

Community
  • 1
  • 1
Tobi
  • 31,405
  • 8
  • 58
  • 90
0

Thanks @Tobi & @Damian, your answers helped me to solve this

After hours of struggle, finally got the answer, FB has just changed the things, now you have to explicitly request for email & other required fields/info of the user

FBRequest *me = [FBRequest requestForGraphPath:@"me?fields=email,first_name,last_name"];
        [me startWithCompletionHandler:^(FBRequestConnection *connection,
                                         NSDictionary<FBGraphUser> *user,
                                         NSError *error) {
           NSString* email= [user objectForKey:@"email"];//use this

        }];
zaheer
  • 893
  • 13
  • 27