小编Die*_*ego的帖子

Facebook登录集成到Parse.com App

我正在尝试在我的应用程序中实现Facebook登录选项.我按照Parse网站和Facebook开发者页面上的所有说明进行操作.我添加了框架,修改了plist文件并添加了正确的代码,但是当我启动App时,我得到了这个异常:

2015-07-14 17:50:08.939 ########[35815:2144465] -[ParseManager coreManager]: unrecognized selector sent to instance 0x7f9cdadad720
2015-07-14 17:50:08.953 ########[35815:2144465] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[ParseManager coreManager]: unrecognized selector sent to instance 0x7f9cdadad720'
*** First throw call stack:
(
0   CoreFoundation                      0x000000010a3cdc65 __exceptionPreprocess + 165
1   libobjc.A.dylib                     0x000000010a066bb7 objc_exception_throw + 45
2   CoreFoundation                      0x000000010a3d50ad -[NSObject(NSObject) doesNotRecognizeSelector:] + 205
3   CoreFoundation                      0x000000010a32b13c ___forwarding___ + 988
4   CoreFoundation                      0x000000010a32acd8 _CF_forwarding_prep_0 + 120
5   ########                          0x0000000105c822f0 +[PFFacebookUtils initializeFacebookWithApplicationLaunchOptions:] + 151
6   ########                          0x0000000105954c6c -[SMAppDelegate …
Run Code Online (Sandbox Code Playgroud)

ios facebook-ios-sdk parse-platform

6
推荐指数
2
解决办法
796
查看次数

Parse.com deviceToken和PFInstallation未保存

我遇到了我的iOS应用程序PFInstallation的奇怪行为.在每个应用程序启动时,我正在注册设备以接收推送通知并在方法上调用以下代码didRegisterForRemoteNotificationsWithDeviceToken:

PFInstallation *currentInstallation = [PFInstallation currentInstallation];

[currentInstallation setDeviceTokenFromData:deviceToken];

NSLog(@"%@", currentInstallation );

[currentInstallation saveInBackgroundWithBlock:^(BOOL succeeded, NSError *error) {
    if (succeeded) {

        NSLog(@"currentInstallation saved" );

    }

    if (error) {

        NSLog(@"currentInstallation NOT saved" );

    }
}];
Run Code Online (Sandbox Code Playgroud)

当我在iphone上安装应用程序时,使用deviceToken正确保存安装.我绝对相信前几天我通过Parse Dashboard手动删除了deviceToken(尝试一下)然后在app重新启动时,设备令牌再次正确保存.我正在使用的某些频道也是如此.今天没有保存deviceToken,也没有保存频道.saveInBackgroundWithBlock成功但deviceToken字段为空.currentInstallation的NSLog包含deviceToken,但它没有保存.在尝试理解这种行为的原因时,我发现如果我在此currentInstallation.deviceToken = @"";之后添加该行,PFInstallation *currentInstallation = [PFInstallation currentInstallation];则deviceToken会被正确保存.消费Parse guru向我解释为什么会发生这种情况以及为什么几天前它不是?我最近在这个应用程序上升级了Parse Framework,这可能是什么原因?

devicetoken ios parse-platform

5
推荐指数
0
解决办法
884
查看次数