mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-04 09:39:23 +00:00
api: add task, res.send as callback
This commit is contained in:
parent
1b3056e63d
commit
7ffb990759
1 changed files with 3 additions and 3 deletions
|
|
@ -215,9 +215,9 @@ api.updateTasks = (req, res, next) ->
|
|||
|
||||
api.createTask = (req, res, next) ->
|
||||
task = req.habit.task
|
||||
addTask req.habit.user, task
|
||||
req.habit.result = code: 201, data: task
|
||||
next()
|
||||
addTask req.habit.user, task, ->
|
||||
req.habit.result = code: 201, data: task
|
||||
next()
|
||||
|
||||
api.sortTask = (req, res, next) ->
|
||||
{id} = req.params
|
||||
|
|
|
|||
Loading…
Reference in a new issue