1
我使用此代碼來獲取朋友的生日會返回一些朋友空擷取Facebook上的朋友與iOS SDK
NSMutableArray *friends = [[NSMutableArray alloc] initWithCapacity:1];
NSArray *resultData = [result objectForKey:@"data"];
if ([resultData count] > 0) {
for (NSUInteger i=0; i<[resultData count] && i < 25; i++) {
[friends addObject:[resultData objectAtIndex:i]];
NSDictionary *friend = [resultData objectAtIndex:i];
long long fbid = [[friend objectForKey:@"id"]longLongValue];
NSString *name = [friend objectForKey:@"name"];
NSString *birthday = [[friend objectForKey:@"birthday"] description];
NSLog(@"id: %lld - Name: %@ - Birthday: %@", fbid, name,birthday);
}
} else {
[self showMessage:@"You have no friends."];
}
[friends release];
由於某種原因,我的一些朋友的生日是空的,雖然我可以在Facebook上看到他們的生日。
這是我的代碼上的東西還是某種特定的用戶隱私設置?