OSDN Git Service

Merge branch 'master' into dev-blockindex
[bytom/vapor.git] / protocol / protocol.go
index 61169e6..99fd915 100644 (file)
@@ -109,7 +109,11 @@ func (c *Chain) BestBlockHash() *bc.Hash {
        return &bestHash
 }
 
-// BestBlockHeader returns the chain tail block
+// BestIrreversibleHeader returns the chain best irreversible block
+func (c *Chain) BestIrreversibleHeader() *types.BlockHeader {
+       return c.bestIrreversibleNode.BlockHeader()
+}
+
 func (c *Chain) BestBlockHeader() *types.BlockHeader {
        c.cond.L.Lock()
        defer c.cond.L.Unlock()