-
Notifications
You must be signed in to change notification settings - Fork 1.9k
FYI: Resumed iOS 10 Notifications results in an error #1002
Comments
@tusharsingh did you set |
I did not set that in the payload. iOS 10 appears to do that with the callback id and then adds it into the dict. |
@tusharsingh right, that's what I was worried about. I'm going to have to upgrade one of my devices to the beta this week. |
+1 |
@tusharsingh I'm pretty sure I can fix this in short order. I've been spending the past two days downloading Xcode8/iOS10 to put on a device. With a little bit of luck this should be done by Monday with a 1.7.2 release out to support stuff. |
@tusharsingh @drastick I just pushed up what I believe to be the fix for this issue. Can you install the plugin from master:
and see if it is resolved for you as well? If I get a positive response from you I'll get a 1.7.2 out. |
@macdonst I just did some preliminary tests and it seems to be working. Thanks! |
@drastick okay, I have to go BBQ for my family but will release an update this weekend. |
@macdonst Working as well for foreground, resume/background, and cold start. Thank you! |
kk, released 1.7.2 with this fix. |
Hi, Sorry but with iOS 10.0.1 and plug-in 1.8.2 I still have the issue only when app is in background. Notification is received by iOS but when I slide it, the app comes in foreground, and nothing happens. I have put an alert just after the "push.on('notification', function(data) {" and I never see it. It works like a charm when app is killed before receiving the push. Any idea? |
I curious how you can recieve push notifications in iOS 10, I only recieve them in debug modus. |
Sorry to come back but I would like to solve this issue if possible. Should I downgrade to 1.7.2 ? Thanks for helping me. |
@macdonst i am using 1.8.4 version of push plugin However, in my iPhone 5 version 10.0.2, push notification doesn't work any more when the app is minimized or in background but it works fine when the device is from cold start |
This thread has been automatically locked. |
Expected Behaviour
App opens and handles notification, which performs an action.
Actual Behaviour
App opens but handlers does not receive the notification or data.
Output shows a failure in push.js:43. notifications[i] is undefined.
Reproduce Scenario (including but not limited to)
Platform and Version (eg. Android 5.0 or iOS 9.2.1)
iOS 10 beta 1 on iPhone 6.
(Android) What device vendor (e.g. Samsung, HTC, Sony...)
Cordova CLI version and cordova platform version
CLI version: 6.1.1
cordova ios 4.1.1
Plugin version
1.7.1
Sample Push Data Payload
{ "uri": "/test" }
Sample Code that illustrates the problem
This all works on iOS 9 using the standard registration notification registration code.
Logs taken while reproducing problem
2016-06-19 12:07:39.558293 App Name[4973:890464] Push Plugin handleActionWithIdentifier com.apple.UNNotificationDefaultActionIdentifier
2016-06-19 12:07:39.558670 App Name[4973:890464] Push Plugin userInfo {
aps = {
alert = "Check this out!";
badge = "-1";
};
callback = "com.apple.UNNotificationDefaultActionIdentifier";
notId = 1411111111111129336;
uri = "/test";
}
2016-06-19 12:07:39.559533 App Name[4973:890464] Push Plugin notId 1411111111111129336
2016-06-19 12:07:39.562717 App Name[4973:890464] Notification received
2016-06-19 12:07:39.562815 App Name[4973:890464] Push Plugin key: alert
2016-06-19 12:07:39.562898 App Name[4973:890464] Push Plugin key: badge
2016-06-19 12:07:39.897422 App Name[4973:890464] Error in Success callbackId: PushNotification1017597311 : TypeError: undefined is not an object (evaluating 'namespaces[i]')
2016-06-19 12:07:40.127061 App Name[4973:890464] active
2016-06-19 12:07:40.127163 App Name[4973:890464] PushPlugin skip clear badge
The text was updated successfully, but these errors were encountered: