mirror of
https://github.com/nbd-wtf/go-nostr.git
synced 2025-09-27 20:38:41 +02:00
send notices on a goroutine.
This commit is contained in:
4
relay.go
4
relay.go
@@ -123,7 +123,9 @@ func (r *Relay) Connect(ctx context.Context) error {
|
|||||||
case "NOTICE":
|
case "NOTICE":
|
||||||
var content string
|
var content string
|
||||||
json.Unmarshal(jsonMessage[1], &content)
|
json.Unmarshal(jsonMessage[1], &content)
|
||||||
r.Notices <- content
|
go func() {
|
||||||
|
r.Notices <- content
|
||||||
|
}()
|
||||||
case "AUTH":
|
case "AUTH":
|
||||||
var challenge string
|
var challenge string
|
||||||
json.Unmarshal(jsonMessage[1], &challenge)
|
json.Unmarshal(jsonMessage[1], &challenge)
|
||||||
|
Reference in New Issue
Block a user