mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2025-01-11 05:20:05 +00:00
fix linter warning
This commit is contained in:
parent
04a6517c5b
commit
432c2a5b26
@ -35,8 +35,7 @@ func HeaderTDKey(number uint64, hash common.Hash) []byte {
|
|||||||
|
|
||||||
func IsHeaderTDKey(k []byte) bool {
|
func IsHeaderTDKey(k []byte) bool {
|
||||||
l := common.BlockNumberLength + common.HashLength + 1
|
l := common.BlockNumberLength + common.HashLength + 1
|
||||||
result := len(k) == l && bytes.Compare(k[l-1:], HeaderTDSuffix) == 0
|
return len(k) == l && bytes.Equal(k[l-1:], HeaderTDSuffix)
|
||||||
return result
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// headerHashKey = headerPrefix + num (uint64 big endian) + headerHashSuffix
|
// headerHashKey = headerPrefix + num (uint64 big endian) + headerHashSuffix
|
||||||
@ -46,8 +45,7 @@ func HeaderHashKey(number uint64) []byte {
|
|||||||
|
|
||||||
func IsHeaderHashKey(k []byte) bool {
|
func IsHeaderHashKey(k []byte) bool {
|
||||||
l := common.BlockNumberLength + 1
|
l := common.BlockNumberLength + 1
|
||||||
result := len(k) == l && bytes.Compare(k[l-1:], HeaderHashSuffix) == 0
|
return len(k) == l && bytes.Equal(k[l-1:], HeaderHashSuffix)
|
||||||
return result
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// headerNumberKey = headerNumberPrefix + hash
|
// headerNumberKey = headerNumberPrefix + hash
|
||||||
|
Loading…
Reference in New Issue
Block a user