Application refers to non-public selector in id (Facebook SDK iOS)

I got this warning when sending my application using Application Loader.

The app references non-public selector in MyApp : id 

This warning could potentially reject my application from checking the Apple AppStore.

My application uses the Facebook SDK iOS 3.1.1 (also tried with 3.1)

+43
ios facebook facebook-ios-sdk application-loader
Jan 21 '13 at 22:02
source share
8 answers

This issue occurs due to the Facebook SDK for iOS.

Application Loader forbids the use of the variable "id" from any class associated with FBGraphUser (perhaps other variables have not been tested either) - for example:

 id<FBGraphUser> friend id<FBGraphUserExtraFields>user 

Facebook reported this issue as of January 2013: Bug Report

The workaround for now is to use these functions:

 [user objectForKey:@"id"] [friend objectForKey:@"id"] 

instead of user.id and friend.id , as shown in different Facebook samples.

+65
Jan 21 '13 at 22:02
source share

Just for an update for people coming here from search engines, this is fixed in the latest Facebook SDK (we just moved our project to the library version 3.7.1 and the verification warnings disappeared).

+3
Sep 16 '13 at 13:22
source share

For everyone who comes here, he is looking for an answer to this. The problem was apparently fixed in v3.14.1 according to the Facebook SDK change log

https://developers.facebook.com/docs/ios/change-log-3.x/

  • The id property for types FBGraphObject , FBGraphPlace , FBOpenGraphAction and FBOpenGraphObject deprecated in favor of objectID to avoid warnings about representing the application store.

  • FBLinkShareParams and FBOpenGraphObject
    deprecated in favor of linkDescription and
    objectDescription , respectively, to avoid the presentation of the application store
    warnings.

+3
May 26 '14 at 21:17
source share

Facebook iOS SDK 3.12 is the same issue in FBGraphUser.h.

Edit

 @property (retain, nonatomic) NSString *id; 

to

 @property (retain, nonatomic) NSString *UserId; 
+2
Feb 14 '14 at 5:41
source share

File FBGraphUser.h

change

@property (persistence, non-atomic) NSString * id;

by

@property (save, non-atomic) NSString * FbUserId;

0
Jan 30 '14 at 17:04
source share

Use the Facebook iOS SDK 3.13. there will be no validation warnings.

0
Mar 11 '14 at 14:22
source share

I solved this problem (where 13.1 will still generate warnings and create an invalid binary in itunesconnect) by downloading the FacebookSDK source from Github ( link ) and using the "build_framework.sh" script in the script directory. Then they added the created framework to my Xcode project and did not receive any more warnings.

0
Apr 30 '14 at 2:39 on
source share

Validation warnings are also provided in version 3.3. I do not know if this will work for other people, but it is a quick workaround that got rid of the error. In FBGraphUser.h around line 41, I changed ...

@property (retain, nonatomic) NSString *id;

to

 @property (retain, nonatomic) NSString *FBUserID; 

I also received the same warning about setting setProfileId, so I went to FBProfilePictureView.h and changed the profile ID on lines 54 and 76 to FBID.

I then updated my FBLoginView information in my ViewController game to reflect the changes. Everything related to FB seems to work in my application, and it passed the Application Loader check.

0
May 6 '14 at 8:14
source share



All Articles