From 4009a52ce7154b5591cd313f4ef2e45393c23c68 Mon Sep 17 00:00:00 2001 From: genekogan Date: Wed, 8 Jan 2025 04:10:11 -0800 Subject: [PATCH] fix cancelg --- eve/api/api_requests.py | 2 +- eve/api/handlers.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/eve/api/api_requests.py b/eve/api/api_requests.py index ab4776d..0934385 100644 --- a/eve/api/api_requests.py +++ b/eve/api/api_requests.py @@ -13,7 +13,7 @@ class TaskRequest(BaseModel): class CancelRequest(BaseModel): - task_id: str + taskId: str user: str diff --git a/eve/api/handlers.py b/eve/api/handlers.py index b272646..eb15c95 100644 --- a/eve/api/handlers.py +++ b/eve/api/handlers.py @@ -52,7 +52,7 @@ async def handle_create(request: TaskRequest): @handle_errors async def handle_cancel(request: CancelRequest): - task = Task.from_mongo(request.task_id) + task = Task.from_mongo(request.taskId) if str(task.user) != request.user: raise APIError( "Unauthorized: Task user does not match user_id", status_code=403