Skip to content

Commit abff016

Browse files
committed
Improve serial checks
1 parent cc00b72 commit abff016

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

src/lib/utils/compatibility.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ export const isMobile = mobilecheck();
2121
export const isSerialSupported =
2222
browser &&
2323
'serial' in navigator &&
24+
navigator.serial !== undefined &&
2425
typeof navigator.serial.getPorts === 'function' &&
2526
typeof navigator.serial.requestPort === 'function' &&
2627
typeof navigator.serial.addEventListener === 'function';

0 commit comments

Comments
 (0)