Преглед изворни кода

deep copy API bug fix

master
kj1352 пре 4 година
родитељ
комит
517a6cc701
1 измењених фајлова са 4 додато и 1 уклоњено
  1. +4
    -1
      src/user-profile/profile-routes.ts

+ 4
- 1
src/user-profile/profile-routes.ts Прегледај датотеку

@@ -38,7 +38,6 @@ userProfileRoutes.get('/deep-copy/', jwtAuthentication, async (request, response
_id: { $in: user.categories.map(id => new ObjectId(id)) }
}).toArray();


try {
for (let i = 0; i < allCategories.length; i += 1) {
if (allCategories[i].shelves) {
@@ -63,6 +62,10 @@ userProfileRoutes.get('/deep-copy/', jwtAuthentication, async (request, response
...allCategories[i],
shelves,
});
} else {
allDeepCategories.push({
...allCategories[i];
})
}
}
} catch {


Loading…
Откажи
Сачувај