diff --git a/src/pages/deleteJob.tsx b/src/pages/deleteJob.tsx index 0109d62..59200f9 100644 --- a/src/pages/deleteJob.tsx +++ b/src/pages/deleteJob.tsx @@ -109,7 +109,7 @@ export const deleteJob = new Elysia() { auth: true, body: t.Object({ - jobIds: t.Array(t.String()), + jobIds: t.Array(t.String(), { maxItems: 100 }), }), }, ); diff --git a/src/pages/history.tsx b/src/pages/history.tsx index d599fd0..4dc404a 100644 --- a/src/pages/history.tsx +++ b/src/pages/history.tsx @@ -300,6 +300,10 @@ export const history = new Elysia().use(userService).get( body: JSON.stringify({ jobIds }), }); + if (!response.ok) { + throw new Error(\`HTTP error! status: \${response.status}\`); + } + const result = await response.json(); if (result.success || result.deleted > 0) {