iOS Crash on messaging.registerDeviceToken

*** Terminating app due to uncaught exception of class ‘Fault’
libc++abi.dylib: terminating with uncaught exception of type Fault

final func handleRegistrationWithDeviceToken(deviceToken: NSData) {
if let devTokenString = Backendless.sharedInstance().messaging.deviceTokenAsString(deviceToken) {
deviceTokenString = devTokenString
print(“➤handleRegistrationWithDeviceToken=(devTokenString)”)
}
Backendless.sharedInstance().messaging.registerDeviceToken(deviceToken)
print(“➤done handleRegistrationWithDeviceToken”)
}

Hi Steven,

Debugging your code is not a free option, due to our Support Policy. If you encounter anything that doesn’t work on our side, please try to describe it and prepare some code which could be run as-is and would show the problem. Otherwise consider buying a Single Incident Support, which is described by the link above.

Please investigate our sample project (see in attachment), it demonstrates how a push notification should be implemented with Backendless MessagingService. This project was created with CocoaPods, so use TestPushNotify.xcworkspace to load it.

TestPushNotify.zip (19.26MB)