diff --git a/lib/nostr.js b/lib/nostr.js index 857a68fc..63a6de6d 100644 --- a/lib/nostr.js +++ b/lib/nostr.js @@ -166,9 +166,10 @@ export default class Nostr { * Close all relay connections */ close () { - const pool = this.ndk.pool - for (const relay of pool.urls()) { - pool.removeRelay(relay) + for (const pool of this.ndk.pools) { + for (const relay of pool.urls()) { + pool.removeRelay(relay) + } } } }