diff --git a/support/aphlict/server/lib/AphlictClientServer.js b/support/aphlict/server/lib/AphlictClientServer.js index 4ee6be0054..b8a903f226 100644 --- a/support/aphlict/server/lib/AphlictClientServer.js +++ b/support/aphlict/server/lib/AphlictClientServer.js @@ -69,6 +69,11 @@ JX.install('AphlictClientServer', { } }); + ws.on('close', function() { + self.getListenerList().removeListener(listener); + log('Disconnected.'); + }); + wss.on('close', function() { self.getListenerList().removeListener(listener); log('Disconnected.');