remove listeners before adding

This commit is contained in:
barisusakli
2014-06-28 16:36:30 -04:00
parent 24aa166ed5
commit e6371ad539

View File

@@ -42,6 +42,7 @@ define('forum/topic/events', ['forum/topic/browsing', 'forum/topic/postTools', '
};
Events.init = function() {
Events.removeListeners();
for(var eventName in events) {
if (events.hasOwnProperty(eventName)) {
socket.on(eventName, events[eventName]);