diff options
| author | raldone01 <[email protected]> | 2025-07-05 19:42:44 +0200 |
|---|---|---|
| committer | raldone01 <[email protected]> | 2025-07-05 19:42:44 +0200 |
| commit | eeb73550ef1cf917159c05ddff574dcfcd10514c (patch) | |
| tree | 19d72d8392ef8ca344c915babf4c7accb8f401c2 | |
| parent | e11047f00367e3b32cbc966de0ad687276aa613b (diff) | |
Remove double text encoder in `SerialPort`.
| -rw-r--r-- | examples/device/webusb_serial/website/serial.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/examples/device/webusb_serial/website/serial.js b/examples/device/webusb_serial/website/serial.js index 304792e05..18bb8a717 100644 --- a/examples/device/webusb_serial/website/serial.js +++ b/examples/device/webusb_serial/website/serial.js @@ -83,8 +83,7 @@ class SerialPort { /// Send data to port send(data) { if (!this.writer) throw new Error('Port not connected'); - const encoder = new TextEncoder(); - return this.writer.write(encoder.encode(data)); + return this.writer.write(data); } async forgetDevice() {} |
