gcode: Don't log debugging output for unknown commands if command is blank

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2020-09-17 02:16:29 -04:00
parent 4c14063404
commit 6bba285f8e
1 changed files with 3 additions and 1 deletions

View File

@ -251,7 +251,9 @@ class GCodeDispatch:
raise gcmd.error(self.printer.get_state_message()[0]) raise gcmd.error(self.printer.get_state_message()[0])
return return
if not cmd: if not cmd:
logging.debug(gcmd.get_commandline()) cmdline = gcmd.get_commandline()
if cmdline:
logging.debug(cmdline)
return return
if cmd.startswith("M117 "): if cmd.startswith("M117 "):
# Handle M117 gcode with numeric and special characters # Handle M117 gcode with numeric and special characters