Skip to content
This repository has been archived by the owner on Jan 9, 2023. It is now read-only.

Commit

Permalink
CB-12815: (ios) Fix bug nativeCallback not executed when app is in ba…
Browse files Browse the repository at this point in the history
…ckground (#49)

* CB-12815: (ios) Fix bug nativeCallback not executed when app is in background

* Update package.json version to 1.2.0-dev
Add back eslint ignore line
  • Loading branch information
Nauzer authored and shazron committed Aug 23, 2018
1 parent 4f8503d commit bf0f236
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cordova-plugin-wkwebview-engine",
"version": "1.1.5-dev",
"version": "1.2.0-dev",
"description": "The official Apache Cordova WKWebView Engine Plugin",
"main": "index.js",
"repository": {
Expand Down
4 changes: 1 addition & 3 deletions src/www/ios/ios-wkwebview-exec.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,9 +124,7 @@ var iOSExec = function () {
iOSExec.nativeCallback = function (callbackId, status, message, keepCallback, debug) {
var success = status === 0 || status === 1;
var args = convertMessageToArgsNativeToJs(message);
setTimeout(function () {
cordova.callbackFromNative(callbackId, success, status, args, keepCallback); // eslint-disable-line
}, 0);
Promise.resolve(cordova.callbackFromNative(callbackId, success, status, args, keepCallback)); // eslint-disable-line
};

// for backwards compatibility
Expand Down

0 comments on commit bf0f236

Please sign in to comment.