diff options
author | xengineering <mail2xengineering@protonmail.com> | 2020-10-19 17:58:51 +0200 |
---|---|---|
committer | xengineering <mail2xengineering@protonmail.com> | 2020-10-19 17:58:51 +0200 |
commit | bf5f3cbad41d9c6c038319bb0311cdef85f6cf8e (patch) | |
tree | fcab3739ec674f1e7ada0869ef2c80f31b4495fe | |
parent | 8c6cc785137489bb786eb00a895c633a1d51b932 (diff) | |
download | iot-barcode-scanner-bf5f3cbad41d9c6c038319bb0311cdef85f6cf8e.tar iot-barcode-scanner-bf5f3cbad41d9c6c038319bb0311cdef85f6cf8e.tar.zst iot-barcode-scanner-bf5f3cbad41d9c6c038319bb0311cdef85f6cf8e.zip |
Remove doubled Newline
-rwxr-xr-x | barcode_transmit_daemon.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/barcode_transmit_daemon.py b/barcode_transmit_daemon.py index 624550e..a2d7eb6 100755 --- a/barcode_transmit_daemon.py +++ b/barcode_transmit_daemon.py @@ -27,7 +27,6 @@ def main(): with open(fifo_path, "r") as fifo: keycode = fifo.read() character = KEYMAP[keycode] - barcode += character if character is "\n": mqtt_service.client.publish( topic, @@ -36,6 +35,8 @@ def main(): retain=False ) barcode = "" + else: + barcode += character except KeyboardInterrupt: pass |