Skip to content

Commit 168494d

Browse files
author
Fatme
authored
Check if device is undefined
1 parent cd3a4cd commit 168494d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/iphone-simulator-xcode-simctl.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ export class XCodeSimctlSimulator extends IPhoneSimulatorNameGetter implements I
235235

236236
public startSimulator(device?: IDevice): void {
237237
// In case the id is undefined, skip verification - we'll start default simulator.
238-
if (device.id) {
238+
if (device && device.id) {
239239
this.verifyDevice(device);
240240
}
241241

0 commit comments

Comments
 (0)