mirror of
https://github.com/nbd-wtf/go-nostr.git
synced 2025-11-19 10:36:42 +01:00
avoid sending to closed Events/UniqueEvents channels.
This commit is contained in:
@@ -152,9 +152,11 @@ func (r *RelayPool) Add(url string, policy RelayPoolPolicy) error {
|
||||
continue
|
||||
}
|
||||
|
||||
subscription.Events <- EventMessage{
|
||||
Relay: nm,
|
||||
Event: event,
|
||||
if !subscription.stopped {
|
||||
subscription.Events <- EventMessage{
|
||||
Relay: nm,
|
||||
Event: event,
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user