This commit is contained in:
Lucas Torroba (@zesme)
2016-05-26 18:40:32 -03:00
parent 01a7880bc9
commit 46be1553f0

View File

@@ -193,10 +193,7 @@ habitrpg.controller("TasksCtrl", ['$scope', '$rootScope', '$location', 'User','N
// Don't allow creation of an empty checklist item
// TODO Provide UI feedback that this item is still blank
} else if ($index == task.checklist.length - 1) {
Tasks.addChecklistItem(task._id, task.checklist[$index])
.then(function (response) {
task.checklist[$index] = response.data.data.checklist[$index];
});
$scope.saveTask(task, true);
task.checklist.push({completed:false, text:''});
focusChecklist(task, task.checklist.length - 1);
} else {