gpt4 book ai didi

iOS 10.3 到 iOS 11 升级 : User stop receiving silent push notifications

转载 作者:塔克拉玛干 更新时间:2023-11-02 22:07:52 26 4
gpt4 key购买 nike

我有很多用户提示说,当他们从 iOS 10.3.3 迁移到昨天发布的 iOS 11 时,他们停止接收静默推送通知。

需要注意的是,如果我已经要求用户注册推送通知,我在 NSUSerDefaults 中有一个设置。我这样做:

[[UIApplication sharedApplication] registerUserNotificationSettings:settings];

仅当用户之前没有被询问过。

现在,如果用户在使用 iOS 10.3.3 时已经注册了通知,并升级到 iOS 11,代码 registerUserNotificationSettings:settings 将永远不会被调用,直到他重新安装。这可能是个问题吗?不过,我认为他已经注册了,没有必要再注册了。

那么我该如何解决这个问题呢?

最佳答案

来自 documentation :

It is recommended that you call this method before you schedule any local notifications or register with the push notification service.

因此建议在每次应用启动时至少调用一次,但应在您的服务器发送推送通知之前。

关于iOS 10.3 到 iOS 11 升级 : User stop receiving silent push notifications,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46320262/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com