state override no pointer

This commit is contained in:
Sina Mahmoodi 2025-10-15 19:15:45 +02:00
parent bbdbcd84ce
commit baa9835ee8
2 changed files with 7 additions and 7 deletions

View file

@ -831,7 +831,7 @@ type SimulateOptions struct {
// SimulateBlock represents a batch of calls to be simulated. // SimulateBlock represents a batch of calls to be simulated.
type SimulateBlock struct { type SimulateBlock struct {
BlockOverrides *ethereum.BlockOverrides `json:"blockOverrides,omitempty"` BlockOverrides *ethereum.BlockOverrides `json:"blockOverrides,omitempty"`
StateOverrides *map[common.Address]ethereum.OverrideAccount `json:"stateOverrides,omitempty"` StateOverrides map[common.Address]ethereum.OverrideAccount `json:"stateOverrides,omitempty"`
Calls []ethereum.CallMsg `json:"calls"` Calls []ethereum.CallMsg `json:"calls"`
} }
@ -839,7 +839,7 @@ type SimulateBlock struct {
func (s SimulateBlock) MarshalJSON() ([]byte, error) { func (s SimulateBlock) MarshalJSON() ([]byte, error) {
type Alias struct { type Alias struct {
BlockOverrides *ethereum.BlockOverrides `json:"blockOverrides,omitempty"` BlockOverrides *ethereum.BlockOverrides `json:"blockOverrides,omitempty"`
StateOverrides *map[common.Address]ethereum.OverrideAccount `json:"stateOverrides,omitempty"` StateOverrides map[common.Address]ethereum.OverrideAccount `json:"stateOverrides,omitempty"`
Calls []interface{} `json:"calls"` Calls []interface{} `json:"calls"`
} }
calls := make([]interface{}, len(s.Calls)) calls := make([]interface{}, len(s.Calls))

View file

@ -920,7 +920,7 @@ func TestSimulateV1WithStateOverrides(t *testing.T) {
opts := ethclient.SimulateOptions{ opts := ethclient.SimulateOptions{
BlockStateCalls: []ethclient.SimulateBlock{ BlockStateCalls: []ethclient.SimulateBlock{
{ {
StateOverrides: &stateOverrides, StateOverrides: stateOverrides,
Calls: []ethereum.CallMsg{ Calls: []ethereum.CallMsg{
{ {
From: from, From: from,