Device Token not received when registering for remote notifications in Swift

前端 未结 8 2070
太阳男子
太阳男子 2021-02-04 10:42

I somehow can not receive the device token when registering for remote notifications. I get the modal saying \"Do you want to allow App X to be able to send you notificaitons\",

8条回答
  •  野趣味
    野趣味 (楼主)
    2021-02-04 11:07

    For Swift 3.0 you can use:

    let deviceTokenString = message.reduce("", {$0 + String(format: "%02X", $1)})
    

提交回复
热议问题