安装ios9.3后我没有得到devicetoken,但之前在ios9.2.1中运行良好。没有得到devicetoken或没有在ios9.3中调用didfailRemotenotification
这里的代码(没有什么特别)
if ([application respondsToSelector:@selector(isRegisteredForRemoteNotifications)]) {
[application registerUserNotificationSettings:[UIUserNotificationSettings settingsForTypes:(UIUserNotificationTypeSound | UIUserNotificationTypeAlert | UIUserNotificationTypeBadge) categories:nil]];
[application registerForRemoteNotifications];
}
else {
// iOS < 8 Notifications
[application registerForRemoteNotificationTypes:
(UIRemoteNotificationTypeBadge | UIRemoteNotificationTypeAlert | UIRemoteNotificationTypeSound)];
}
我也是在9.3.1得到这个同样的问题,你有没有发现这方面的任何解决方案或原因是什么? –
Righnow我没有任何解决方案。 – SmarterSusheel