datastore: store multiline commands as one entry

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
Eric Callahan committed 2024-11-17 15:18:32 -05:00
1 parent d4ef626961
commit ccfe32f236
1 file changed
+2 -5
+2 -5
View File
@@ -155,12 +155,9 @@ class DataStore:
def _store_gcode_command(self, script: str) -> None:
curtime = time.time()
for cmd in script.split('\n'):
cmd = cmd.strip()
if not cmd:
continue
if script.strip():
self.gcode_queue.append(
{'message': cmd, 'time': curtime, 'type': "command"}
{'message': script, 'time': curtime, 'type': "command"}
)
async def _handle_gcode_store_request(self,