Fix bug causing users to disconnect
This commit is contained in:
parent
20f0ca6666
commit
9947b537b6
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "shout",
|
||||
"description": "The self-hosted web IRC client",
|
||||
"version": "0.38.6",
|
||||
"version": "0.38.7",
|
||||
"author": "Mattias Erming",
|
||||
"preferGlobal": true,
|
||||
"bin": {
|
||||
|
@ -283,9 +283,14 @@ Client.prototype.sort = function(data) {
|
||||
};
|
||||
|
||||
Client.prototype.quit = function() {
|
||||
this.sockets.in(this.id).sockets.forEach(function(socket) {
|
||||
socket.disconnect(true);
|
||||
});
|
||||
var sockets = this.sockets.sockets;
|
||||
var room = sockets.adapter.rooms[this.id] || [];
|
||||
for (var user in room) {
|
||||
var socket = sockets.adapter.nsp.connected[user];
|
||||
if (socket) {
|
||||
socket.disconnect();
|
||||
}
|
||||
}
|
||||
this.networks.forEach(function(network) {
|
||||
var irc = network.irc;
|
||||
if (network.connected) {
|
||||
|
Loading…
Reference in New Issue
Block a user