node-serialport
node-serialport copied to clipboard
Fix encoding for stream _write
Fix per https://github.com/serialport/node-serialport/issues/2566
This matches the definition of _write definition for Duplex streams
Signed-off-by: Gareth Hancock [email protected]
Hmm, do we need to look at changing the _writev function too?
https://github.com/serialport/node-serialport/blob/0585e64b7b3a353f6d5427c405ba4a0dd989563a/packages/stream/lib/index.ts#L275
I'm suspect that this is the correct type as nodejs used to pass undefined there all the time. Curious how that's been upgraded for older libraries and packages. Whatever type changes make us look like a stream are fine by me.