mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-11 22:43:47 +00:00
fix(tx): fix bug in *TransactionData UnmarshalJSON (#184)
* Fix bug for TransactionData json unmarshal * clean up Co-authored-by: HAOYUatHZ <haoyu@protonmail.com>
This commit is contained in:
parent
22963a115d
commit
0bdd2e0575
1 changed files with 2 additions and 2 deletions
|
|
@ -10,7 +10,7 @@ import (
|
||||||
type TransactionData struct {
|
type TransactionData struct {
|
||||||
IsCreate bool `json:"isCreate"`
|
IsCreate bool `json:"isCreate"`
|
||||||
From common.Address `json:"from"`
|
From common.Address `json:"from"`
|
||||||
*Transaction
|
Transaction
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewTraceTransaction returns a transaction that will serialize to the trace
|
// NewTraceTransaction returns a transaction that will serialize to the trace
|
||||||
|
|
@ -21,6 +21,6 @@ func NewTraceTransaction(tx *Transaction, blockNumber uint64, config *params.Cha
|
||||||
return &TransactionData{
|
return &TransactionData{
|
||||||
From: from,
|
From: from,
|
||||||
IsCreate: tx.To() == nil,
|
IsCreate: tx.To() == nil,
|
||||||
Transaction: tx,
|
Transaction: *tx,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue