forked from snxraven/LinkUp-P2P-Chat
Lol i tried to iterate over not-iterable object
This commit is contained in:
parent
7399585d9e
commit
6980520a85
@ -22,7 +22,7 @@ class Client extends EventEmitter {
|
|||||||
this.swarm.on('update', () => {
|
this.swarm.on('update', () => {
|
||||||
console.log(`Peers count: ${this.swarm.connections.size}`);
|
console.log(`Peers count: ${this.swarm.connections.size}`);
|
||||||
if(this.swarm.connections.size > 0) {
|
if(this.swarm.connections.size > 0) {
|
||||||
console.log([...this.swarm]);
|
console.log([this.swarm]);
|
||||||
process.exit(-1);
|
process.exit(-1);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user