Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/sorting/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Swift 未使用Firebase云消息传递调用UNNotificationServiceExtension didReceive方法_Swift_Firebase_Firebase Cloud Messaging_Apple Push Notifications - Fatal编程技术网

Swift 未使用Firebase云消息传递调用UNNotificationServiceExtension didReceive方法

Swift 未使用Firebase云消息传递调用UNNotificationServiceExtension didReceive方法,swift,firebase,firebase-cloud-messaging,apple-push-notifications,Swift,Firebase,Firebase Cloud Messaging,Apple Push Notifications,我一直在尝试使用notification Service扩展创建自定义iOS推送通知,但无法在通知到达时调用UnnotificationService扩展中的didReceive方法。我觉得我已经尝试了关于StackOverflow的所有建议,但仍然无法解决我的问题。下面是我发送给Firebase cloud messaging的json-有人介意检查json中是否存在任何可能导致我的问题的格式问题吗?谢谢 message = { apns: { headers: { '

我一直在尝试使用notification Service扩展创建自定义iOS推送通知,但无法在通知到达时调用UnnotificationService扩展中的didReceive方法。我觉得我已经尝试了关于StackOverflow的所有建议,但仍然无法解决我的问题。下面是我发送给Firebase cloud messaging的json-有人介意检查json中是否存在任何可能导致我的问题的格式问题吗?谢谢

message = {
  apns: {
    headers: {
      'apns-push-type': 'alert'
    },
    payload: {
      aps: {
        category: 'TrendingPost',
        alert: {
          title: title,
          body: body,
        },
        mutable_content: true,
      },
      type: 'post',
      postID: postID,
      urlImageString: communityLogoURL,
    },
  },
  topic: communityID
};