add await for shell command

This commit is contained in:
Lei PAN
2023-07-07 13:25:08 +02:00
parent 84871558e9
commit 25696e4f78
+1 -1
View File
@@ -136,7 +136,7 @@ class CommandorPage {
async loadPage() { async loadPage() {
logWithDevice(this.device.serial() + ":loadPage() called, with port:" + this.port, this.device); logWithDevice(this.device.serial() + ":loadPage() called, with port:" + this.port, this.device);
try { try {
this.device.shell("am start -n com.android.chrome/com.google.android.apps.chrome.Main") await this.device.shell("am start -n com.android.chrome/com.google.android.apps.chrome.Main")
await delay(5 * 1000); await delay(5 * 1000);
} catch (e) { } catch (e) {
console.log(e) console.log(e)