CB-11869 Fix cordova-js android exec tests

Useragent Regexp result is null in node environment - add a check for it
Updated cordova-js
Increased e2e create specs timeout
This commit is contained in:
daserge
2016-09-19 15:56:48 +03:00
parent 9cf38f8705
commit 30325e4f32
3 changed files with 11 additions and 11 deletions
+1 -1
View File
@@ -112,7 +112,7 @@ androidExec.init = function() {
//
//It's ugly, but it's necessary.
var check = navigator.userAgent.toLowerCase().match(/android\s[0-9].[0-9]/);
var version_code = check[0].match(/4.[0-3].*/);
var version_code = check && check[0].match(/4.[0-3].*/);
if (version_code != null && nativeToJsBridgeMode == nativeToJsModes.EVAL_BRIDGE) {
nativeToJsBridgeMode = nativeToJsModes.ONLINE_EVENT;
}