中断任务接口优化

This commit is contained in:
刘雪峰
2024-01-10 21:22:00 +08:00
parent e027179ee4
commit 90df5146a8
2 changed files with 3 additions and 2 deletions
+2 -2
View File
@@ -108,8 +108,8 @@ def register_routes():
prompt_id = json_data["prompt_id"]
current_queue = PromptServer.instance.prompt_queue.get_current_queue()
queue_running = current_queue[0]
if queue_running is not None:
if queue_running[1] == prompt_id:
if queue_running is not None and len(queue_running) > 0:
if len(queue_running[0]) > 0 and queue_running[0][1] == prompt_id:
nodes.interrupt_processing()
delete_func = lambda a: a[1] == prompt_id
+1
View File
@@ -56,6 +56,7 @@ class EasyApiWorkflows {
"channel": "red"
}
}
delete output[o]['_meta']
}
return output
}