Skip to content

Commit

Permalink
Lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefan-Ethernal committed Feb 19, 2024
1 parent 232da1b commit f546ff1
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 8 deletions.
8 changes: 6 additions & 2 deletions types/access_list_tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -204,9 +204,13 @@ func (tx *AccessListTxn) setHash(h Hash) {
// Use UnmarshalRLP in most cases
func (tx *AccessListTxn) unmarshalRLPFrom(p *fastrlp.Parser, v *fastrlp.Value) error {
numOfElems := 11
var values rlpValues

values, err := v.GetElems()
var (
values rlpValues
err error
)

values, err = v.GetElems()
if err != nil {
return err
}
Expand Down
8 changes: 6 additions & 2 deletions types/dynamic_fee_tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,13 @@ func (tx *DynamicFeeTx) setHash(h Hash) { tx.Hash = h }
// Use UnmarshalRLP in most cases
func (tx *DynamicFeeTx) unmarshalRLPFrom(p *fastrlp.Parser, v *fastrlp.Value) error {
numOfElems := 12
var values rlpValues

values, err := v.GetElems()
var (
values rlpValues
err error
)

values, err = v.GetElems()
if err != nil {
return err
}
Expand Down
8 changes: 6 additions & 2 deletions types/legacy_tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,13 @@ func (tx *LegacyTx) setHash(h Hash) { tx.Hash = h }
// Use UnmarshalRLP in most cases
func (tx *LegacyTx) unmarshalRLPFrom(p *fastrlp.Parser, v *fastrlp.Value) error {
num := 9
var values rlpValues

values, err := v.GetElems()
var (
values rlpValues
err error
)

values, err = v.GetElems()
if err != nil {
return err
}
Expand Down
1 change: 1 addition & 0 deletions types/rlp_unmarshal.go
Original file line number Diff line number Diff line change
Expand Up @@ -390,6 +390,7 @@ func (r *rlpValues) dequeueValue() *fastrlp.Value {
if len(*r) == 0 {
return nil
}

val := (*r)[0]
*r = (*r)[1:]

Expand Down
8 changes: 6 additions & 2 deletions types/state_tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,13 @@ func (tx *StateTx) setHash(h Hash) { tx.Hash = h }
// Use UnmarshalRLP in most cases
func (tx *StateTx) unmarshalRLPFrom(p *fastrlp.Parser, v *fastrlp.Value) error {
numOfElems := 10
var values rlpValues

values, err := v.GetElems()
var (
values rlpValues
err error
)

values, err = v.GetElems()
if err != nil {
return err
}
Expand Down

0 comments on commit f546ff1

Please sign in to comment.