Skip to content

Commit

Permalink
Remove unused code in node.newL1Client() (#2128)
Browse files Browse the repository at this point in the history
  • Loading branch information
AnkushinDaniil authored Sep 10, 2024
1 parent b89e078 commit 71c7ca2
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions node/node.go
Original file line number Diff line number Diff line change
Expand Up @@ -290,20 +290,14 @@ func newL1Client(cfg *Config, chain *blockchain.Blockchain, log utils.SimpleLogg
}

network := chain.Network()
if err != nil {
return nil, fmt.Errorf("find core contract address for network %s: %w", network.String(), err)
}

var ethSubscriber *l1.EthSubscriber
ethSubscriber, err = l1.NewEthSubscriber(cfg.EthNode, network.CoreContractAddress)
if err != nil {
return nil, fmt.Errorf("set up ethSubscriber: %w", err)
}

l1Client, err := l1.NewClient(ethSubscriber, chain, log), nil
if err != nil {
return nil, fmt.Errorf("set up l1 client: %w", err)
}
l1Client := l1.NewClient(ethSubscriber, chain, log)

if cfg.Metrics {
l1Client.WithEventListener(makeL1Metrics())
Expand Down

0 comments on commit 71c7ca2

Please sign in to comment.