diff --git a/ui/index.html b/ui/index.html index 4d9b498c..7f38417d 100644 --- a/ui/index.html +++ b/ui/index.html @@ -952,7 +952,13 @@ async function doMakeImage(reqBody, batchCount) { res = undefined progressBar.style.display = 'none' } else { - res = JSON.parse(finalJSON) + try { + res = JSON.parse(finalJSON) + } catch (e) { + console.log('Parse error, invalid JSON', finalJSON) + throw e + } + progressBar.style.display = 'none' if (res.status !== 'succeeded') {