mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 10:52:25 +00:00
force presente of to in eip-5806 delegate tx
This commit is contained in:
parent
0efbc0b794
commit
0a6941be8e
1 changed files with 3 additions and 2 deletions
|
|
@ -420,9 +420,10 @@ func (tx *Transaction) UnmarshalJSON(input []byte) error {
|
|||
return errors.New("missing required field 'nonce' in transaction")
|
||||
}
|
||||
itx.Nonce = uint64(*dec.Nonce)
|
||||
if dec.To != nil {
|
||||
itx.To = dec.To
|
||||
if dec.To == nil {
|
||||
return errors.New("missing required field 'to' in transaction")
|
||||
}
|
||||
itx.To = *dec.To
|
||||
if dec.Gas == nil {
|
||||
return errors.New("missing required field 'gas' for txdata")
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue