fix: restrict topic backfill to logged-in users when browsing to a category

This commit is contained in:
Julian Lam
2026-01-19 21:44:14 -05:00
parent 428b6e730a
commit 0262bb83f3

View File

@@ -151,7 +151,7 @@ topicsController.get = async function getTopic(req, res, next) {
res.set('Link', `<${href}>; rel="alternate"; type="application/activity+json"`);
}
if (!utils.isNumber(topicData.mainPid)) {
if (req.uid > 0 && !utils.isNumber(topicData.mainPid)) {
// not awaited on purpose so topic loading is not blocked
activitypub.notes.backfill(topicData.mainPid);
}