mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-05-08 00:17:38 +02:00
remove listeners before adding
This commit is contained in:
@@ -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]);
|
||||
|
||||
Reference in New Issue
Block a user