We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0e8a420 commit cdbced9Copy full SHA for cdbced9
service/start.go
@@ -59,9 +59,14 @@ func (svc *service) startNostr(ctx context.Context) error {
59
}),
60
))
61
62
+ // initially try connect to relays (if hub has no apps, pool won't connect to apps by default)
63
+ for _, relayUrl := range svc.cfg.GetRelayUrls() {
64
+ _, err := pool.EnsureRelay(relayUrl)
65
+ if err != nil {
66
+ logger.Logger.WithError(err).WithField("relay_url", relayUrl).Error("failed to initially connect to relay")
67
+ }
68
69
go func() {
- // wait a few seconds for relays to connect
- time.Sleep(5 * time.Second)
70
for {
71
select {
72
case <-ctx.Done():
0 commit comments