From 5f17c48de23deeaca1f05f46ccbf471e27f88810 Mon Sep 17 00:00:00 2001 From: Cody Tolene Date: Mon, 28 Apr 2025 23:06:24 -0500 Subject: [PATCH] Fix use of the '!' operator inside the 'in' operator --- uart.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/uart.js b/uart.js index 5352ef1..dd6c6e2 100644 --- a/uart.js +++ b/uart.js @@ -507,7 +507,7 @@ To do: DATA : 0x8000, // Sent after FILE_SEND with blocks of data for the file FILE_RECV : 0xA000 // receive a file - returns a series of PT_TYPE_DATA packets, with a final zero length packet to end } - if (!pkType in PKTYPES) throw new Error("'pkType' not one of "+Object.keys(PKTYPES)); + if (!(pkType in PKTYPES)) throw new Error("'pkType' not one of "+Object.keys(PKTYPES)); let connection = this; return new Promise((resolve,reject) => { let timeout;