From a4a92f6f4a5fa296813f6f42403abd312a574ee2 Mon Sep 17 00:00:00 2001 From: pim Date: Fri, 27 Dec 2019 20:16:09 +0100 Subject: [PATCH] GenericGcodeDriver: Send postHttpUploadGcode before instead of after autoPlay --- .../liblasercut/drivers/GenericGcodeDriver.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/de/thomas_oster/liblasercut/drivers/GenericGcodeDriver.java b/src/main/java/de/thomas_oster/liblasercut/drivers/GenericGcodeDriver.java index d7e17878..715d93ac 100644 --- a/src/main/java/de/thomas_oster/liblasercut/drivers/GenericGcodeDriver.java +++ b/src/main/java/de/thomas_oster/liblasercut/drivers/GenericGcodeDriver.java @@ -782,14 +782,14 @@ protected void disconnect(String jobname) throws IOException, URISyntaxException { out.close(); http_upload(new URI(getHttpUploadUrl()), outputBuffer.toString("UTF-8"), jobname); - if (this.isAutoPlay()) - { - http_play(jobname); - } if (this.getPostHttpUploadGcode() != null && !this.getPostHttpUploadGcode().equals("")) { http_commands(this.getPostHttpUploadGcode(), jobname); } + if (this.isAutoPlay()) + { + http_play(jobname); + } } else {