*If server is not available, remove from the available array and call removeRelay.

This commit is contained in:
Derrick Hammer 2022-07-27 00:12:41 -04:00
parent ad062df383
commit 3f843b5266
1 changed files with 2 additions and 0 deletions

View File

@ -150,6 +150,8 @@ export default class DHT {
const connection = this._relays.get(available[relayIndex]) as string;
if (!(await this.isServerAvailable(connection))) {
available.splice(relayIndex, 1);
this.removeRelay(available[relayIndex]);
continue;
}