We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0aaa2c2 commit 815eca2Copy full SHA for 815eca2
lib/appium-driver.ts
@@ -320,8 +320,10 @@ export class AppiumDriver {
320
try {
321
const devicesInfos = IOSController.devicesDisplaysInfos();
322
const matches = devicesInfos.filter(d => sessionInfoDetails.deviceName.includes(d.deviceType));
323
- const deviceType = matches[matches.length - 1];
324
- args.device.viewportRect.y += deviceType.statBarHeight * deviceType.density;
+ if (matches && matches.length > 0) {
+ const deviceType = matches[matches.length - 1];
325
+ args.device.viewportRect.y += deviceType.actionBarHeight * deviceType.density;
326
+ }
327
} catch (error) { }
328
}
329
0 commit comments