fix(api): remove duplicate to_dict() call in /api/graph/tasks
TaskManager.list_tasks() already returns a list of dicts (it calls t.to_dict() internally at task.py:170). The endpoint then called .to_dict() again on these plain dicts, raising AttributeError on every request to GET /api/graph/tasks.
This commit is contained in:
parent
1536a79334
commit
32fa3c8987
|
|
@ -554,7 +554,7 @@ def list_tasks():
|
||||||
|
|
||||||
return jsonify({
|
return jsonify({
|
||||||
"success": True,
|
"success": True,
|
||||||
"data": [t.to_dict() for t in tasks],
|
"data": tasks,
|
||||||
"count": len(tasks)
|
"count": len(tasks)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue