Description
Hello,
I have an issue where trackAppOpenedWithRemoteNotificationPayload is being called in iOS7 but no push open event is shown in Parse.com.
The issue is detailed here on SO: http://stackoverflow.com/questions/32103788/parse-not-sending-push-open-notifications-for-ios7
I have followed the guide for the relevant Push setup with Parse.
When testing the app on an iOS7 device and iOS8 device the same method is called when opening from a push:
- (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo fetchCompletionHandler:(void (^)(UIBackgroundFetchResult))completionHandler {
DebugLog(@"%s",__PRETTY_FUNCTION__);
if (application.applicationState == UIApplicationStateInactive) {
[PFAnalytics trackAppOpenedWithRemoteNotificationPayload:userInfo];
}
if (completionHandler) {
completionHandler(UIBackgroundFetchResultNoData);
}
[PFPush handlePush:userInfo];
}
It appears that although the [PFAnalytics trackAppOpenedWithRemoteNotificationPayload:userInfo];
method is called on iOS7 the data is not shown in Parse.
For example, checking the Push that has been sent shows the amount of Opens. If I send a push to an iOS7 device and iOS8, the same part of code is being called. However, it is only recorded for the iOS8 version. Is there anything else I should be doing?
We have followed the relevant guide: https://parse.com/docs/ios/guide#push-notifications
This is also implemented:
- (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo {
DebugLog(@"%s",__PRETTY_FUNCTION__);
if (application.applicationState == UIApplicationStateInactive) {
// The application was just brought from the background to the foreground,
// so we consider the app as having been "opened by a push notification."
[PFAnalytics trackAppOpenedWithRemoteNotificationPayload:userInfo];
}
[PFPush handlePush:userInfo];
}
Thanks