mirror of
https://github.com/sudoxnym/habitica-self-host.git
synced 2026-07-18 03:52:54 +00:00
fix(client): Stop duplicating completed todos (#7709)
* Deduping completed tasks on load. closes #7708 * Addressing paglias' comment
This commit is contained in:
parent
e441f45ac5
commit
30cf4f5a96
1 changed files with 5 additions and 1 deletions
|
|
@ -156,7 +156,11 @@ habitrpg.controller("TasksCtrl", ['$scope', '$rootScope', '$location', 'User','N
|
|||
$scope._today = moment().add({days: 1});
|
||||
|
||||
$scope.loadedCompletedTodos = function () {
|
||||
if (Tasks.loadedCompletedTodos === true) return;
|
||||
if (Tasks.loadedCompletedTodos === true) {
|
||||
return;
|
||||
}
|
||||
|
||||
User.user.todos = _.reject(User.user.todos, 'completed')
|
||||
|
||||
Tasks.getUserTasks(true)
|
||||
.then(function (response) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue