pinned news sorting

This commit is contained in:
tmshv committed 2016-11-24 17:50:04 +03:00
1 parent a18abe215c
commit 4034df5c2d
1 file changed
+1
+1
View File
@@ -29,6 +29,7 @@ function news() {
const now = new Date();
const pinned = skip !== 0 ? [] : await c('timeline')
.find({until: {$gte: now}})
.sort({date: -1})
.toArray();
const id = i => i._id;