From 3c70127405f70424f8c1cdd137b693d8b4d447de Mon Sep 17 00:00:00 2001 From: huangminlinux <380108184@qq.com> Date: Wed, 12 Jul 2017 10:14:26 +0800 Subject: [PATCH 1/2] fix notification in backgroup bug --- src/ios/Plugins/AppDelegate+JPush.m | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/ios/Plugins/AppDelegate+JPush.m b/src/ios/Plugins/AppDelegate+JPush.m index 1d8af8b..0cd5a51 100644 --- a/src/ios/Plugins/AppDelegate+JPush.m +++ b/src/ios/Plugins/AppDelegate+JPush.m @@ -119,7 +119,9 @@ NSDictionary *_launchOptions; break; } [JPushPlugin fireDocumentEvent:eventName jsString:[userInfo toJsonString]]; - completionHandler(UIBackgroundFetchResultNewData); + dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(30 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{ + completionHandler(UIBackgroundFetchResultNewData); + }); } -(void)jpushNotificationCenter:(UNUserNotificationCenter *)center willPresentNotification:(UNNotification *)notification withCompletionHandler:(void (^)(NSInteger))completionHandler{ From 0436cfcf3ef2ba458f40630cee5a85b9c8ba9427 Mon Sep 17 00:00:00 2001 From: Hevin Date: Wed, 12 Jul 2017 10:16:10 +0800 Subject: [PATCH 2/2] Update version to 3.2.2 --- README.md | 2 +- package.json | 2 +- plugin.xml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 5822eb5..de269e8 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # JPush PhoneGap / Cordova Plugin [![Build Status](https://travis-ci.org/jpush/jpush-phonegap-plugin.svg?branch=master)](https://travis-ci.org/jpush/jpush-phonegap-plugin) -[![release](https://img.shields.io/badge/release-3.2.1-blue.svg)](https://github.com/jpush/jpush-phonegap-plugin/releases) +[![release](https://img.shields.io/badge/release-3.2.2-blue.svg)](https://github.com/jpush/jpush-phonegap-plugin/releases) [![platforms](https://img.shields.io/badge/platforms-iOS%7CAndroid-lightgrey.svg)](https://github.com/jpush/jpush-phonegap-plugin) [![weibo](https://img.shields.io/badge/weibo-JPush-blue.svg)](http://weibo.com/jpush?refer_flag=1001030101_&is_all=1) diff --git a/package.json b/package.json index bef763d..435089d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "jpush-phonegap-plugin", - "version": "3.2.1", + "version": "3.2.2", "description": "JPush for cordova plugin", "cordova": { "id": "jpush-phonegap-plugin", diff --git a/plugin.xml b/plugin.xml index 77788cc..042cab6 100644 --- a/plugin.xml +++ b/plugin.xml @@ -2,7 +2,7 @@ + version="3.2.2"> JPush JPush for cordova plugin