Skip to content

Commit 418fe70

Browse files
committed
EVM event subscription should reconnect on the last received height
1 parent 7097da4 commit 418fe70

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

services/ingestion/event_subscriber.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -232,11 +232,11 @@ func (r *RPCEventSubscriber) subscribe(ctx context.Context, height uint64) <-cha
232232
return
233233
}
234234

235-
if err := connect(lastReceivedHeight + 1); err != nil {
235+
if err := connect(lastReceivedHeight); err != nil {
236236
eventsChan <- models.NewBlockEventsError(
237237
fmt.Errorf(
238238
"failed to resubscribe for events on height: %d, with: %w",
239-
lastReceivedHeight+1,
239+
lastReceivedHeight,
240240
err,
241241
),
242242
)

0 commit comments

Comments
 (0)