mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-18 15:17:25 +01:00
v3 migration: fix createdAt date
This commit is contained in:
@@ -173,7 +173,7 @@ function processUsers (afterId) {
|
||||
newUser.tasksOrder[`${oldTask.type}s`].push(oldTask._id);
|
||||
}
|
||||
|
||||
var allTasksFields = ['_id', 'type', 'text', 'notes', 'tags', 'value', 'priority', 'attribute', 'challenge', 'reminders', 'userId', 'legacyId'];
|
||||
var allTasksFields = ['_id', 'type', 'text', 'notes', 'tags', 'value', 'priority', 'attribute', 'challenge', 'reminders', 'userId', 'legacyId', 'createdAt'];
|
||||
// using mongoose models is too slow
|
||||
if (oldTask.type === 'habit') {
|
||||
oldTask = _.pick(oldTask, allTasksFields.concat(['history', 'up', 'down']));
|
||||
|
||||
Reference in New Issue
Block a user