We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 55d9f6f commit 63c84ccCopy full SHA for 63c84cc
1 file changed
indexer/indexer.go
@@ -125,17 +125,18 @@ func (i *Indexer) addPendingHeights(p *[]uint64) error {
125
}
126
127
func (i *Indexer) onDBSyncComplete(r db_buffer.SyncResult) {
128
+ if r.SyncedHeights == nil {
129
+ zap.S().Errorf("onDBSyncComplete received nil SyncedHeights. Check db_sync code!")
130
+ return
131
+ }
132
+
133
if r.Error != nil {
134
zap.S().Errorf(r.Error.Error())
135
// Remove WIP heights
136
_ = tracker.UpdateInProgressHeight(false, r.SyncedHeights, i.Id, i.DbConn)
137
return
138
139
- if r.SyncedHeights == nil {
- return
- }
-
140
err := tracker.UpdateAndRemoveWipHeights(r.SyncedHeights, i.Id, i.DbConn)
141
if err != nil {
142
0 commit comments