mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-19 15:48:04 +01:00
[#1677] only set TASK_DELETED on tasks in current challenge (don't clobber other
challenges)
This commit is contained in:
@@ -52,7 +52,8 @@ var syncChalToUser = function(chal, user) {
|
||||
|
||||
// Flag deleted tasks as "broken"
|
||||
_.each(user.tasks, function(task){
|
||||
if (!chal.tasks[task.id]) task.challenge.broken = 'TASK_DELETED';
|
||||
if (task.challenge && task.challenge.id==chal._id && !chal.tasks[task.id])
|
||||
task.challenge.broken = 'TASK_DELETED';
|
||||
})
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user