From 6a843447b1d2964fa3acb8dd90723a6c6807a658 Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Wed, 1 Feb 2023 04:42:29 -0500 Subject: [PATCH] *Update dist --- dist/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dist/index.js b/dist/index.js index 9595ecf..e3fc484 100644 --- a/dist/index.js +++ b/dist/index.js @@ -53,7 +53,7 @@ export default class HyperswarmWeb extends EventEmitter { this._activeRelay.on("close", () => { this._activeRelay = undefined; }); - } while (relays.length > 0); + } while (relays.length > 0 && !this._activeRelay); if (!this._activeRelay) { throw new Error("Failed to find an available relay"); }