mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-18 03:31:03 +01:00
feat: some additional work to properly save and retrieve remote topic data
This commit is contained in:
@@ -23,11 +23,8 @@ controller.get = async function (req, res, next) {
|
||||
// topics.getTopicData(tid),
|
||||
]);
|
||||
|
||||
const topicData = {
|
||||
tid,
|
||||
postCount: 6,
|
||||
category: {}, // todo
|
||||
};
|
||||
const topicData = await topics.getTopicData(tid);
|
||||
topicData.category = {}; // todo
|
||||
|
||||
let currentPage = parseInt(req.query.page, 10) || 1;
|
||||
const pageCount = Math.max(1, Math.ceil((topicData && topicData.postcount) / settings.postsPerPage));
|
||||
|
||||
Reference in New Issue
Block a user