From 8b787309d88180cf7092174da925c4fa792f13a5 Mon Sep 17 00:00:00 2001 From: TropiiDev Date: Mon, 28 Apr 2025 08:49:58 -0400 Subject: [PATCH] Fix bug with updating tasks v0.0.7 --- api.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/api.py b/api.py index 568c3dc..cf1c646 100644 --- a/api.py +++ b/api.py @@ -48,6 +48,8 @@ async def update_user_task(task: UpdateTask, session: SessionDep, current_user: user_data = task.model_dump(exclude_unset=True) new_task = user_data + if user_db.tasks is None: + user_db.tasks = [] # Filter out the task with matching title and keep all others updated_tasks = [