1
0
forked from Kieran/snort

fix: auth

This commit is contained in:
Kieran 2023-11-11 13:31:38 +00:00
parent 04a49755e6
commit 6f396c825c
Signed by: Kieran
GPG Key ID: DE71CEB3925BE941

View File

@ -153,6 +153,7 @@ export class NostrSystem extends EventEmitter<NostrSystemEvents> implements Syst
c.on("eose", s => this.#onEndOfStoredEvents(c, s));
c.on("disconnect", code => this.#onRelayDisconnect(c, code));
c.on("connected", r => this.#onRelayConnected(c, r));
c.on("auth", (c, r, cb) => this.emit("auth", c, r, cb));
await c.Connect();
} else {
// update settings if already connected
@ -219,6 +220,7 @@ export class NostrSystem extends EventEmitter<NostrSystemEvents> implements Syst
c.on("eose", s => this.#onEndOfStoredEvents(c, s));
c.on("disconnect", code => this.#onRelayDisconnect(c, code));
c.on("connected", r => this.#onRelayConnected(c, r));
c.on("auth", (c, r, cb) => this.emit("auth", c, r, cb));
await c.Connect();
return c;
}