From 807e9573fb46ee157a866213a79824a212143906 Mon Sep 17 00:00:00 2001 From: Marc-Andre Ferland Date: Thu, 20 Oct 2022 20:36:45 -0400 Subject: [PATCH] Check result status, not json object. --- ui/media/js/main.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/media/js/main.js b/ui/media/js/main.js index dc309d6b..239b1354 100644 --- a/ui/media/js/main.js +++ b/ui/media/js/main.js @@ -518,7 +518,7 @@ async function doMakeImage(task) { }) renderRequest = await res.json() // status_code 503, already a task running. - } while (renderRequest.status_code === 503 && await asyncDelay(RETRY_DELAY_IF_SERVER_IS_BUSY)) + } while (res.status === 503 && await asyncDelay(RETRY_DELAY_IF_SERVER_IS_BUSY)) if (typeof renderRequest?.stream !== 'string') { console.log('Endpoint response: ', renderRequest)