iOS Push Notification Registration Error

When registering for push in my appDelegate the registration fails with the following error:

  java.lang.NullPointerException

Push WAS working properly with this app until now.

APPID: 408D24A7-14B7-2887-FF2C-64C0CC571300

Testing tethered to Xcode, with my certificate in Sandbox mode.

Hi Jay,

What version of the Backendless SDK for iOS you have installed?

Regards,

Mark

Using Backendless (4.0.15)

Do you set a channel name when you register the device?

I register with the following code:

#pragma mark Push Notifications

  • (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken {

[backendless.messaging registerDevice:deviceToken response:^(NSString *response) {

DLog(@“Backendless registered for push notifications\n%@”, response);

} error:^(Fault *fault) {

DLog(@“Error registering Backendless for push notifications: %@”, fault.detail);

}];

}

Could you please modify the signature to specify the “default” channel and try again?

Thanks, Mark, that fixed the issue, at least in the sandbox. I’ll build an enterprise app and test in production mode later today.

JK

Good to hear. We will make an adjustment on the server to support the use-case when a device is registered without an explicit reference to a channel.

Regards,
Mark

My app always sends notifications to all devices, so I don’t use any other Channels. Your API documentation says the following about the registerDevice method channel argument:

For the method without the argument, the “Default” channel is used;

JK

You are correct, it is supposed to work like, but there was a regression in the 4.3.0 release. We will be fixing it ASAP.

Regards,
Mark