mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-26 06:36:43 +00:00
core/filtermaps: polish
This commit is contained in:
parent
73b1ff2cd4
commit
7c59af1044
1 changed files with 2 additions and 0 deletions
|
|
@ -103,6 +103,7 @@ func (cv *ChainView) Receipts(number uint64) types.Receipts {
|
|||
blockHash := cv.BlockHash(number)
|
||||
if blockHash == (common.Hash{}) {
|
||||
log.Error("Chain view: block hash unavailable", "number", number, "head", cv.headNumber)
|
||||
return nil
|
||||
}
|
||||
return cv.chain.GetReceiptsByHash(blockHash)
|
||||
}
|
||||
|
|
@ -114,6 +115,7 @@ func (cv *ChainView) RawReceipts(number uint64) types.Receipts {
|
|||
blockHash := cv.BlockHash(number)
|
||||
if blockHash == (common.Hash{}) {
|
||||
log.Error("Chain view: block hash unavailable", "number", number, "head", cv.headNumber)
|
||||
return nil
|
||||
}
|
||||
return cv.chain.GetRawReceiptsByHash(blockHash)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue