Spaces:
Running
Running
fix(assistant): assistant sorting
Browse files
src/routes/assistants/+page.server.ts
CHANGED
@@ -56,8 +56,8 @@ export const load = async ({ url, locals }) => {
|
|
56 |
.getCollections()
|
57 |
.assistants.find(filter)
|
58 |
.sort({
|
59 |
-
...(sort === SortKey.TRENDING && {
|
60 |
-
|
61 |
_id: 1,
|
62 |
})
|
63 |
.skip(NUM_PER_PAGE * pageIndex)
|
|
|
56 |
.getCollections()
|
57 |
.assistants.find(filter)
|
58 |
.sort({
|
59 |
+
...(sort === SortKey.TRENDING && { last24HoursCount: -1 }),
|
60 |
+
userCount: -1,
|
61 |
_id: 1,
|
62 |
})
|
63 |
.skip(NUM_PER_PAGE * pageIndex)
|