mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-30 18:46:01 +01:00
feat: flesh out more topic info, fix navigator
This commit is contained in:
@@ -70,6 +70,11 @@ Notes.assertTopic = async (uid, id) => {
|
||||
sorted.map(n => n.timestamp),
|
||||
];
|
||||
|
||||
const postercount = chain.reduce((set, cur) => {
|
||||
set.add(cur.uid);
|
||||
return set;
|
||||
}, new Set());
|
||||
|
||||
await Promise.all([
|
||||
db.setObject(`topicRemote:${tid}`, {
|
||||
tid,
|
||||
@@ -79,6 +84,7 @@ Notes.assertTopic = async (uid, id) => {
|
||||
title: 'TBD',
|
||||
slug: `remote?resource=${encodeURIComponent(tid)}`,
|
||||
postcount: sorted.length,
|
||||
postercount,
|
||||
}),
|
||||
db.sortedSetAdd(`tidRemote:${tid}:posts`, timestamps, ids),
|
||||
Notes.assert(uid, chain),
|
||||
|
||||
Reference in New Issue
Block a user