Skip to content

Commit

Permalink
Remove obsolete check for JellyBean (apacheGH-534) (apache#544)
Browse files Browse the repository at this point in the history
to work properly on Android Pie

was introduced in dc0bfeb (CB-11828)

Resolves apache#534

Co-authored-by: <pradiv-kumar@users.noreply.github.com>
Co-authored-by: Christopher J. Brody <chris.brody@gmail.com>
  • Loading branch information
Chris Brody committed Nov 16, 2018
1 parent dbc99e8 commit 9f6c332
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions cordova-js-src/exec.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,17 +109,6 @@ function androidExec(success, fail, service, action, args) {
}

androidExec.init = function() {
//CB-11828
//This failsafe checks the version of Android and if it's Jellybean, it switches it to
//using the Online Event bridge for communicating from Native to JS
//
//It's ugly, but it's necessary.
var check = navigator.userAgent.toLowerCase().match(/android\s[0-9].[0-9]/);
var version_code = check && check[0].match(/4.[0-3].*/);
if (version_code != null && nativeToJsBridgeMode == nativeToJsModes.EVAL_BRIDGE) {
nativeToJsBridgeMode = nativeToJsModes.ONLINE_EVENT;
}

bridgeSecret = +prompt('', 'gap_init:' + nativeToJsBridgeMode);
channel.onNativeReady.fire();
};
Expand Down

0 comments on commit 9f6c332

Please sign in to comment.