mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-28 15:46:43 +00:00
14 lines
339 B
Go
14 lines
339 B
Go
package ethapi
|
|
|
|
import (
|
|
"context"
|
|
)
|
|
|
|
// GetRootHash returns root hash for given start and end block
|
|
func (s *PublicBlockChainAPI) GetRootHash(ctx context.Context, starBlockNr uint64, endBlockNr uint64) (string, error) {
|
|
root, err := s.b.GetRootHash(ctx, starBlockNr, endBlockNr)
|
|
if err != nil {
|
|
return "", err
|
|
}
|
|
return root, nil
|
|
}
|