In iOS, I am not able to get user email id even the permission says can request a user's email

ios
login
email

#1

Hi,

I am using twitter login for my ios application. I am gettin permission error when i tried to fetch user email id. Though i have asked for email permission on apps.twitter.com and my application permission says can request user’s email.

URl contain my app ID:-


https://apps.twitter.com/app/13652563/keys

Login is fine i am able to create TWTRSession, getting TWTRUser but when i call TWTRShareEmailViewController for email it returns error in its completion block.

Below is my code:

[[Twitter sharedInstance] logInWithViewController: [self rootController] completion:^(TWTRSession *session, NSError *error)
     {
        if (session) {
            [[[Twitter sharedInstance] APIClient] loadUserWithID:[session userID]
                                                      completion:^(TWTRUser *user,
                                                                   NSError *error)
             {
                     
                     **TWTRShareEmailViewController *shareEmailViewController =**
**                     [[TWTRShareEmailViewController alloc]**
**                      initWithCompletion:^(NSString *email, NSError *errorWhileEmail

)**
**                      {**
**                      }];**
                     
                     [[self rootController] presentViewController:shareEmailViewController
                                                         animated:YES
                                                       completion:nil];
                     
                 } 
             }];
        } 
    }];