diff --git a/consensus/XDPoS/utils/utils.go b/consensus/XDPoS/utils/utils.go index 7c11509d17..0b40983da3 100644 --- a/consensus/XDPoS/utils/utils.go +++ b/consensus/XDPoS/utils/utils.go @@ -10,7 +10,6 @@ import ( "github.com/XinFinOrg/XDPoSChain/common" "github.com/XinFinOrg/XDPoSChain/log" "github.com/XinFinOrg/XDPoSChain/rlp" - "golang.org/x/crypto/sha3" ) func Position(list []common.Address, x common.Address) int { @@ -89,13 +88,3 @@ func DecodeBytesExtraFields(b []byte, val interface{}) error { return fmt.Errorf("consensus version %d is not defined, or this block is v1 block", b[0]) } } - -func rlpHash(x interface{}) (h common.Hash) { - hw := sha3.NewLegacyKeccak256() - err := rlp.Encode(hw, x) - if err != nil { - log.Error("[rlpHash] Fail to hash item", "Error", err) - } - hw.Sum(h[:0]) - return h -}