forked from extern/easydiffusion
Don't throw an error if a task was stopped before it started processing
This commit is contained in:
parent
344fa729a5
commit
9af75bf9b2
@ -582,6 +582,10 @@ async function doMakeImage(task) {
|
|||||||
}
|
}
|
||||||
} while (serverState.time > (Date.now() - (10 * 1000)) && serverState.task !== renderRequest.task)
|
} while (serverState.time > (Date.now() - (10 * 1000)) && serverState.task !== renderRequest.task)
|
||||||
if (serverState.session !== 'pending' && serverState.session !== 'running' && serverState.session !== 'buffer') {
|
if (serverState.session !== 'pending' && serverState.session !== 'running' && serverState.session !== 'buffer') {
|
||||||
|
if (serverState.session === 'stopped') {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
throw new Error('Unexpected server task state: ' + serverState.session || 'Undefined')
|
throw new Error('Unexpected server task state: ' + serverState.session || 'Undefined')
|
||||||
}
|
}
|
||||||
while (serverState.task === renderRequest.task && serverState.session === 'pending') {
|
while (serverState.task === renderRequest.task && serverState.session === 'pending') {
|
||||||
|
Loading…
Reference in New Issue
Block a user