Skip to content

Commit 6e23de1

Browse files
distractedm1ndtzdybal
authored andcommitted
fix: saving block height after committing validators to db
1 parent b1df434 commit 6e23de1

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

block/manager.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -401,9 +401,6 @@ func (m *Manager) publishBlock(ctx context.Context) error {
401401
return err
402402
}
403403

404-
// Only update the stored height after successfully submitting to DA layer
405-
m.store.SetHeight(block.Header.Height)
406-
407404
// Commit the new state and block which writes to disk on the proxy app
408405
_, _, err = m.executor.Commit(ctx, newState, block, responses)
409406
if err != nil {
@@ -432,6 +429,9 @@ func (m *Manager) publishBlock(ctx context.Context) error {
432429
return err
433430
}
434431

432+
// Only update the stored height after successfully submitting to DA layer and committing to the DB
433+
m.store.SetHeight(block.Header.Height)
434+
435435
m.publishHeader(block)
436436

437437
return nil

0 commit comments

Comments
 (0)