fix(closing): more proper closing without errors

This commit is contained in:
Alexey Kasyanchuk
2018-06-22 23:51:57 +03:00
parent 35157457c7
commit 16164c25d8
2 changed files with 14 additions and 4 deletions

View File

@ -181,6 +181,7 @@ class p2p {
for (const client in this.clients) {
this.clients[client]._socket.destroy();
}
this.peers = []
return promise
}