mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-01 07:21:15 +00:00
apiv2: same as before - user.get('tasks'), not model.get('tasks')
This commit is contained in:
parent
69ca37d3b0
commit
360a8f7d9e
1 changed files with 1 additions and 1 deletions
|
|
@ -55,7 +55,7 @@ router.post '/', auth, (req, res) ->
|
|||
if action.op == "score"
|
||||
if action.task.type=="daily" || action.task.type=="todo"
|
||||
# flip completed state. Since checkbox is not binded to model unlike when you click through Derby website.
|
||||
completed = model.get "tasks[#{action.task.id}].completed"
|
||||
completed = req.user.get "tasks.#{action.task.id}.completed"
|
||||
req.user.set("tasks.#{action.task.id}.completed", !completed)
|
||||
misc.score(model, action.task.id, action.dir, true)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue