From db831bb5e13fc39f4cbd528e2769bcfd493c1e62 Mon Sep 17 00:00:00 2001 From: sverben <59171289+sverben@users.noreply.github.com> Date: Mon, 19 Aug 2024 18:09:54 +0200 Subject: [PATCH] fix: playwright serialport !== SerialPort --- src/lib/state/workspace.svelte.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/state/workspace.svelte.ts b/src/lib/state/workspace.svelte.ts index 2c617ed..c7d9d8a 100644 --- a/src/lib/state/workspace.svelte.ts +++ b/src/lib/state/workspace.svelte.ts @@ -180,7 +180,7 @@ function createPortState() { } function getLeaphyPort(port: SerialPort | USBDevice): LeaphyPort { - if (port instanceof SerialPort) return port; + if ("readable" in port) return port; if (port?.vendorId === 1027) return new MockedFTDISerialPort(port);