refactor request builder to handle relay hints

This commit is contained in:
2023-05-25 19:52:03 +01:00
parent ca92b365e0
commit 9a33466c7c
11 changed files with 242 additions and 118 deletions

View File

@ -211,7 +211,10 @@ export class Connection {
break;
}
case "EVENT": {
this.OnEvent?.(msg[1], msg[2]);
this.OnEvent?.(msg[1], {
...msg[2],
relays: [this.Address]
});
this.Stats.EventsReceived++;
this.#UpdateState();
break;