Skip to content

Commit

Permalink
support nil env in ConcurrentEVMClient (#664)
Browse files Browse the repository at this point in the history
  • Loading branch information
AnieeG authored Aug 15, 2023
1 parent e890dec commit d637ca0
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions blockchain/ethereum.go
Original file line number Diff line number Diff line change
Expand Up @@ -1199,12 +1199,10 @@ func ConcurrentEVMClient(networkSettings EVMNetwork, env *environment.Environmen
return NewEVMClient(networkSettings, env)
}
ecl := &EthereumMultinodeClient{}
if _, ok := env.URLs[networkSettings.Name]; !ok {
return nil, fmt.Errorf("network %s not found in environment", networkSettings.Name)
}
if env == nil {
log.Warn().Str("Network", networkSettings.Name).Msg("No test environment deployed")
} else {
if env != nil {
if _, ok := env.URLs[networkSettings.Name]; !ok {
return nil, fmt.Errorf("network %s not found in environment", networkSettings.Name)
}
networkSettings.URLs = env.URLs[networkSettings.Name]
}
for idx, networkURL := range networkSettings.URLs {
Expand Down

0 comments on commit d637ca0

Please sign in to comment.