From b381271ba940f3a60a760b45a04e256e2c3c1db6 Mon Sep 17 00:00:00 2001 From: Omar Brikaa Date: Mon, 2 May 2022 13:25:46 +0200 Subject: [PATCH] Add backward compatibility in v2.js Set run property to compile if it doesn't exist in v2.js --- api/src/api/v2.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/api/src/api/v2.js b/api/src/api/v2.js index e95382a..ac1269e 100644 --- a/api/src/api/v2.js +++ b/api/src/api/v2.js @@ -264,7 +264,11 @@ router.post('/execute', async (req, res) => { await job.prime(); - const result = await job.execute(); + let result = await job.execute(); + // Backward compatibility when the run stage is not started + if (result.run === undefined) { + result.run = result.compile; + } await job.cleanup();