+3
-1
cmd/monarch/firehose.go
+3
-1
cmd/monarch/firehose.go
···
13
13
func NewFirehoseConnection(ctx context.Context, cctx *cli.Context, cursorSvc *CursorService) (*websocket.Conn, error) {
14
14
url := fmt.Sprintf("wss://%s/xrpc/com.atproto.sync.subscribeRepos", cctx.String("relay-host"))
15
15
curs, err := cursorSvc.GetFirehoseCursor()
16
-
if err == nil { // reversed
16
+
if err != nil {
17
+
slog.Error("error getting firehose cursor", "err", err)
18
+
} else if curs > 0 {
17
19
url += fmt.Sprintf("?cursor=%d", curs)
18
20
}
19
21