允许voip推送

This commit is contained in:
imhao183
2021-03-27 19:37:30 +08:00
parent 7bae37f479
commit b088f4b9b9
2 changed files with 2 additions and 5 deletions

View File

@@ -6,7 +6,4 @@ apns.voip_cer_pwd=123456
apns.alert=default
apns.voip_alert=ring.caf
# 苹果要求使用voip推送必须使用callkit不然会停掉voip推送。由于大陆政策callkit被禁止所以在大陆无法使用voip推送。
# 苹果政策参考 https://developer.apple.com/documentation/pushkit/pkpushregistrydelegate/2875784-pushregistry?language=objc
# On iOS 13.0 and later, if you fail to report a call to CallKit, the system will terminate your app. Repeatedly failing to report calls may cause the system to stop delivering any more VoIP push notifications to your app. If you want to initiate a VoIP call without using CallKit, register for push notifications using the UserNotifications framework instead of PushKit. For more information, see UserNotifications.
apns.voip_feature=false
apns.voip_feature=true

View File

@@ -74,7 +74,7 @@ public class ApnsServer {
.setClientCredentials(new File(mConfig.voipCerPath), mConfig.voipCerPwd)
.setMetricsListener(productMetricsListener)
.build();
developSvc = new ApnsClientBuilder()
developVoipSvc = new ApnsClientBuilder()
.setApnsServer(ApnsClientBuilder.DEVELOPMENT_APNS_HOST)
.setClientCredentials(new File(mConfig.voipCerPath), mConfig.voipCerPwd)
.setMetricsListener(developMetricsListener)