feat: show unread categories based on unread topics (#12317)

* feat: show unread categories based on unread topics

if a category has unread topics in one of its children then mark category unread
deprecate cid:<cid>:read_by_uid sets
upgrade script to remove the old sets

* chore: up harmony
This commit is contained in:
Barış Soner Uşaklı
2024-01-30 17:47:06 -05:00
committed by GitHub
parent ef06be6d3f
commit 45cfb3691e
15 changed files with 107 additions and 39 deletions

View File

@@ -14,7 +14,7 @@ const categoriesController = module.exports;
categoriesController.get = async function (req, res, next) {
const [categoryData, parent, selectedData] = await Promise.all([
categories.getCategories([req.params.category_id], req.uid),
categories.getCategories([req.params.category_id]),
categories.getParents([req.params.category_id]),
helpers.getSelectedCategory(req.params.category_id),
]);