mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-15 08:23:46 +00:00
chg: no need for txhash
This commit is contained in:
parent
0f74eca8c6
commit
d3fe97ad4e
1 changed files with 2 additions and 3 deletions
|
|
@ -5,7 +5,6 @@ import (
|
||||||
"math/big"
|
"math/big"
|
||||||
|
|
||||||
"github.com/maticnetwork/bor/common"
|
"github.com/maticnetwork/bor/common"
|
||||||
"github.com/maticnetwork/bor/crypto"
|
|
||||||
"github.com/maticnetwork/bor/rlp"
|
"github.com/maticnetwork/bor/rlp"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -96,13 +95,13 @@ func decodeStoredBorReceiptRLP(r *BorReceiptForStorage, blob []byte) error {
|
||||||
// DeriveFields fills the receipts with their computed fields based on consensus
|
// DeriveFields fills the receipts with their computed fields based on consensus
|
||||||
// data and contextual infos like containing block and transactions.
|
// data and contextual infos like containing block and transactions.
|
||||||
func (r *BorReceipt) DeriveFields(hash common.Hash, number uint64) error {
|
func (r *BorReceipt) DeriveFields(hash common.Hash, number uint64) error {
|
||||||
txHash := common.BytesToHash(crypto.Keccak256(append([]byte("matic-receipt-"), hash.Bytes()...)))
|
// txHash := common.BytesToHash(crypto.Keccak256(append([]byte("bor-receipt-"), hash.Bytes()...)))
|
||||||
|
|
||||||
// The derived log fields can simply be set from the block and transaction
|
// The derived log fields can simply be set from the block and transaction
|
||||||
for j := 0; j < len(r.Logs); j++ {
|
for j := 0; j < len(r.Logs); j++ {
|
||||||
r.Logs[j].BlockNumber = number
|
r.Logs[j].BlockNumber = number
|
||||||
r.Logs[j].BlockHash = hash
|
r.Logs[j].BlockHash = hash
|
||||||
r.Logs[j].TxHash = txHash
|
// r.Logs[j].TxHash = txHash
|
||||||
r.Logs[j].TxIndex = uint(0)
|
r.Logs[j].TxIndex = uint(0)
|
||||||
r.Logs[j].Index = uint(j)
|
r.Logs[j].Index = uint(j)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue