diff --git a/src/ios/CDVParsePlugin.m b/src/ios/CDVParsePlugin.m index 10041589..6c12c058 100644 --- a/src/ios/CDVParsePlugin.m +++ b/src/ios/CDVParsePlugin.m @@ -132,6 +132,18 @@ - (void)swizzled_application:(UIApplication *)application didReceiveRemoteNotifi // Call existing method [self swizzled_application:application didReceiveRemoteNotification:userInfo]; [PFPush handlePush:userInfo]; + + /* + //HACK WAY + + NSString *message = userInfo[@"aps"][@"alert"]; + NSString *eventName = @"didReceiveRemoteNotification"; + + [self.viewController.webView stringByEvaluatingJavaScriptFromString: + [NSString stringWithFormat:@"setTimeout( function() { cordova.fireDocumentEvent('%@', {message:'%@'} ) }, 0);", eventName, message]]; + + NSLog(@"%@ : %@", eventName, message); + */ } @end