diff --git a/lib/server/swarm.js b/lib/server/swarm.js index 773caba..2c6f49a 100644 --- a/lib/server/swarm.js +++ b/lib/server/swarm.js @@ -29,15 +29,7 @@ function Swarm (infoHash, server) { peer_id: peer.peerId } self._onAnnounceStopped(params, peer, peer.peerId) - - // When a websocket peer is evicted, and it's not in any other swarms, close - // the websocket to conserve server resources. - if (peer.socket && peer.socket.infoHashes.length === 0) { - try { - peer.socket.close() - peer.socket = null - } catch (err) {} - } + peer.socket = null }) }