Skip to content

Commit

Permalink
bug fix starting tree index at 1
Browse files Browse the repository at this point in the history
  • Loading branch information
sh-cha committed Aug 12, 2024
1 parent 70e7626 commit 8e4d7a8
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
2 changes: 1 addition & 1 deletion executor/host/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ func (h Host) QueryHeightsOfOutputTxWithL2BlockNumber(bridgeId int64, l2BlockNum
}
if len(res.Txs) == 0 {
// no output tx found
return 0, 0, 0, nil
return 0, 0, 1, nil
}

l2StartHeight := uint64(0)
Expand Down
5 changes: 0 additions & 5 deletions node/node.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ type Node struct {
rawBlockHandler nodetypes.RawBlockHandlerFn

// status info
startHeightInitialized bool
lastProcessedBlockHeight uint64
running bool
}
Expand Down Expand Up @@ -97,10 +96,6 @@ func (n *Node) Initialize(startHeight uint64) error {
return n.loadSyncInfo(startHeight)
}

func (n *Node) HeightInitialized() bool {
return n.startHeightInitialized
}

func (n *Node) Start(ctx context.Context) {
if n.running {
return
Expand Down

0 comments on commit 8e4d7a8

Please sign in to comment.