我的应用程序实现了新的iOS 10丰富推送NotificationService扩展。
一切都能在iOS 10上按预期工作,但我也想支持iOS 10之前的设备-当然不是丰富推送,而只是常规推送。将Xcode中的部署目标降低到8.0或9.0并尝试在较旧的模拟器或设备上运行时,出现以下错误:
Simulator: The operation couldn’t be completed. (LaunchServicesError error 0.)
Device: This app contains an app extension that specifies an extension point identifier that is not supported on this version of iOS for the value of the NSExtensionPointIdentifier key in its Info.plist.
Apple官方找不到任何内容说明您添加了服务扩展后,您的应用只能在iOS 10+上运行-有人可以确认吗?
最佳答案
Bhavuk Jain谈论的是如何在较旧的ios上支持通知,但不能解决LaunchServicesError。为了解决这个问题,您需要转到“部署信息”下的扩展目标->常规->设置部署目标(在这种情况下为10.0)。
关于ios - 如何在iOS 10之前的版本中使用UNNotificationServiceExtension运行应用程序?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40412905/