Fixed task update

This commit is contained in:
Marcin-Ramotowski
2025-04-30 17:02:39 +00:00
parent acf3f75fc7
commit c728956099
2 changed files with 19 additions and 2 deletions

View File

@ -106,5 +106,5 @@ def validate_task_data(task):
except ValueError:
abort(400, "Incorrect datetime format. Expected DD-MM-YYYY HH:MM")
done = task.get('done')
if done not in (0, 1):
if done is not None and done not in (0, 1):
abort(400, "Incorrect done field value. Expected 0 or 1")