From 3ba4d2aa2bb227503c2bfb1b0e9bdfafbc312c6c Mon Sep 17 00:00:00 2001 From: barisusakli Date: Fri, 17 Oct 2014 01:11:55 -0400 Subject: [PATCH] get correct count only from one of the active users elements --- public/src/client/topic/browsing.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/src/client/topic/browsing.js b/public/src/client/topic/browsing.js index ad8e4e9129..3d84dfc577 100644 --- a/public/src/client/topic/browsing.js +++ b/public/src/client/topic/browsing.js @@ -23,7 +23,7 @@ define('forum/topic/browsing', function() { Browsing.onUserEnter = function(data) { var activeEl = $('.thread_active_users'); var user = activeEl.find('a[data-uid="' + data.uid + '"]'); - if (!user.length && activeEl.children().length < 10) { + if (!user.length && activeEl.first().children().length < 10) { addUserIcon(data); } else if (user.length) { user.attr('data-count', parseInt(user.attr('data-count'), 10) + 1);