mirror of
https://github.com/sudoxnym/habitica-self-host.git
synced 2026-07-14 18:22:21 +00:00
Fixed case where click on trash icon left Checklist string. Test for task.checklist[0] was unnecessary in saveTask().
This commit is contained in:
parent
07d4fc1184
commit
cf069cbca2
1 changed files with 1 additions and 1 deletions
|
|
@ -43,7 +43,7 @@ habitrpg.controller("TasksCtrl", ['$scope', '$rootScope', '$location', 'User','N
|
|||
};
|
||||
|
||||
$scope.saveTask = function(task, stayOpen) {
|
||||
if (task.checklist && task.checklist[0])
|
||||
if (task.checklist)
|
||||
task.checklist = _.filter(task.checklist,function(i){return !!i.text});
|
||||
User.user.ops.updateTask({params:{id:task.id},body:task});
|
||||
if (!stayOpen) task._editing = false;
|
||||
|
|
|
|||
Loading…
Reference in a new issue