Node.js based forum software built for the modern web
fix: sync client category watch states with core so unread badge updates for watching users (#14648)
palmoni577518451526a
diff --git a/public/src/client/header/unread.js b/public/src/client/header/unread.jsindex 8e606aa6fd..d9cc9fe675 100644--- a/public/src/client/header/unread.js+++ b/public/src/client/header/unread.js@@ -5,7 +5,8 @@ define('forum/header/unread', ['hooks'], function (hooks) {const watchStates = {ignoring: 1,notwatching: 2,- watching: 3,+ tracking: 3,+ watching: 4,};unread.initUnreadTopics = function () {@@ -15,7 +16,9 @@ define('forum/header/unread', ['hooks'], function (hooks) {if (data && data.posts && data.posts.length && unreadTopics) {const post = data.posts[0];if (parseInt(post.uid, 10) === parseInt(app.user.uid, 10) ||- (!post.topic.isFollowing && post.categoryWatchState !== watchStates.watching)+ (!post.topic.isFollowing &&+ post.categoryWatchState !== watchStates.watching &&+ post.categoryWatchState !== watchStates.tracking)) {return;}