Commit bcf59234 authored by zhiqiangxu's avatar zhiqiangxu Committed by GitHub

avoid nil pointer error for `requireEventualBatcherTxType` (#13827)

parent 884876d9
......@@ -307,7 +307,7 @@ func TestBatcherAutoDA(t *testing.T) {
b, err := l1Client.BlockByNumber(ctx, nil)
require.NoError(t, err)
for _, tx := range b.Transactions() {
if tx.To().Cmp(cfg.DeployConfig.BatchInboxAddress) != 0 {
if tx.To() == nil || tx.To().Cmp(cfg.DeployConfig.BatchInboxAddress) != 0 {
continue
}
if typ := tx.Type(); typ == txType {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment