From 634465fdd61c446eb50be7297375be7b1f9e17fe Mon Sep 17 00:00:00 2001 From: Simon Voordouw Date: Thu, 6 Jul 2017 15:31:57 +0200 Subject: [PATCH] move deleting start/endgcode files to stopFetch --- src/rest/api/api_printer.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rest/api/api_printer.lua b/src/rest/api/api_printer.lua index a45a8ee..4be0d31 100644 --- a/src/rest/api/api_printer.lua +++ b/src/rest/api/api_printer.lua @@ -73,6 +73,7 @@ end local function stopFetch() io.popen("killall print-fetch") + io.popen("rm /tmp/startcode /tmp/endcode") end function M.progress(request, response) @@ -190,7 +191,6 @@ function M.stop_POST(request, response) if not printer or not printer:hasSocket() then return end stopFetch() - io.popen("rm /tmp/startcode /tmp/endcode") setCurrentPrint(nil) if(argGcode == nil) then