From e45581701f0f2043e889a68bb9d0a89d759de301 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Magalh=C3=A3es?= Date: Sun, 19 Jan 2025 12:54:38 +0000 Subject: [PATCH] chore: tiny refactor of code --- src/colony_print/scripts/printer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/colony_print/scripts/printer.py b/src/colony_print/scripts/printer.py index a8b315e..a02d569 100644 --- a/src/colony_print/scripts/printer.py +++ b/src/colony_print/scripts/printer.py @@ -27,9 +27,9 @@ def save(id, printer=None): job_id = result["id"] result = api.wait_job(job_id) - if not "output_data" in result: raise appier.OperationalError(message="No output data in result") + data_b64 = result["output_data"] data = base64.b64decode(data_b64) with open("output.pdf", "wb") as file: