Merge pull request #11307 from wangtunan/fix/stop_task_func_need_use_async_await_syntax

fix: stopTask func need use async/await syntax
This commit is contained in:
Timothy Jaeryang Baek
2025-03-30 21:45:32 -07:00
committed by GitHub

View File

@@ -1693,9 +1693,10 @@
history.messages[responseMessage.id] = responseMessage;
};
const stopResponse = () => {
const stopResponse = async () => {
if (taskId) {
const res = stopTask(localStorage.token, taskId).catch((error) => {
const res = await stopTask(localStorage.token, taskId).catch((error) => {
toast.error(`${error}`);
return null;
});