add client-side unread count support for the "new" filter

This commit is contained in:
Ben Lubar
2016-04-08 13:54:51 -05:00
parent 217f0c5652
commit 114e957b0f
2 changed files with 8 additions and 0 deletions

View File

@@ -245,6 +245,7 @@ SocketUser.getUnreadCounts = function(socket, data, callback) {
}
async.parallel({
unreadTopicCount: async.apply(topics.getTotalUnread, socket.uid),
unreadNewTopicCount: async.apply(topics.getTotalUnread, socket.uid, 'new'),
unreadChatCount: async.apply(messaging.getUnreadCount, socket.uid),
unreadNotificationCount: async.apply(user.notifications.getUnreadCount, socket.uid)
}, callback);