From fca382dd5109a8447ed7ba51d485de255487bd6d Mon Sep 17 00:00:00 2001 From: Johan Nyman Date: Mon, 4 Dec 2023 15:38:00 +0100 Subject: [PATCH] fix: remove hack (possible HID.HID that exposed a devicePath) --- packages/node/src/methods.ts | 8 -------- 1 file changed, 8 deletions(-) diff --git a/packages/node/src/methods.ts b/packages/node/src/methods.ts index 14bc103..e00e2a9 100644 --- a/packages/node/src/methods.ts +++ b/packages/node/src/methods.ts @@ -57,14 +57,6 @@ export async function setupXkeysPanel( productId: devicePathOrHIDDevice.productId, interface: devicePathOrHIDDevice.interface, } - } else if ( - typeof devicePathOrHIDDevice === 'object' && - typeof (devicePathOrHIDDevice as any).devicePath === 'string' - ) { - // (backwards compatibility): has { devicePath: string } - - devicePath = (devicePathOrHIDDevice as any).devicePath - device = await HID.HIDAsync.open(devicePath) } else if (typeof devicePathOrHIDDevice === 'string') { // is string (path)