Skip to content

Commit 3b038f6

Browse files
debug unexpected zkevm client situation
1 parent f4be6e0 commit 3b038f6

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

jsonrpc/client/zkevm.go

+3
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ func (c *Client) BatchByNumber(ctx context.Context, number *big.Int) (*types.Bat
5050
if err != nil {
5151
return nil, err
5252
}
53+
if result == nil {
54+
return nil, fmt.Errorf("unesxpected error, couldn't get batch from RPC, but it didn't return error. RPC response: %+v", response)
55+
}
5356

5457
return result, nil
5558
}

0 commit comments

Comments
 (0)