You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ja...@apache.org on 2019/06/19 21:44:41 UTC
[cordova-paramedic] branch master updated: fix: really take the
last webview context (instead of first)
This is an automated email from the ASF dual-hosted git repository.
janpio pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cordova-paramedic.git
The following commit(s) were added to refs/heads/master by this push:
new 1821243 fix: really take the last webview context (instead of first)
1821243 is described below
commit 182124374a12b34b206c34511a942ab020d49a7e
Author: Jan Piotrowski <pi...@gmail.com>
AuthorDate: Wed Jun 19 23:44:37 2019 +0200
fix: really take the last webview context (instead of first)
by reverting the array first before going through it
---
lib/appium/helpers/wdHelper.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/appium/helpers/wdHelper.js b/lib/appium/helpers/wdHelper.js
index b7b056b..679dcd1 100644
--- a/lib/appium/helpers/wdHelper.js
+++ b/lib/appium/helpers/wdHelper.js
@@ -119,6 +119,7 @@ module.exports.getWebviewContext = function (driver, retries) {
.contexts()
.then(function (contexts) {
// take the last webview context
+ contexts.reverse();
for (let i = 0; i < contexts.length; i++) {
if (contexts[i].indexOf('WEBVIEW') >= 0) return contexts[i];
}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org