Skip to content

Commit

Permalink
add checking
Browse files Browse the repository at this point in the history
  • Loading branch information
beer-1 committed Nov 15, 2024
1 parent 9d2d6eb commit be14a97
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions app/ante/ante.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,18 +44,24 @@ func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) {
if options.AccountKeeper == nil {
return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "account keeper is required for ante builder")
}

if options.BankKeeper == nil {
return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "bank keeper is required for ante builder")
}

if options.SignModeHandler == nil {
return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "sign mode handler is required for ante builder")
}

if options.EVMKeeper == nil {
return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "EVM keeper is required for ante builder")
}
if options.IBCkeeper == nil {
return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "IBC keeper is required for ante builder")
}

Check warning on line 58 in app/ante/ante.go

View check run for this annotation

Codecov / codecov/patch

app/ante/ante.go#L57-L58

Added lines #L57 - L58 were not covered by tests
if options.OPChildKeeper == nil {
return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "OPChild keeper is required for ante builder")
}

Check warning on line 61 in app/ante/ante.go

View check run for this annotation

Codecov / codecov/patch

app/ante/ante.go#L60-L61

Added lines #L60 - L61 were not covered by tests
if options.AuctionKeeper == nil {
return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "Auction keeper is required for ante builder")
}

Check warning on line 64 in app/ante/ante.go

View check run for this annotation

Codecov / codecov/patch

app/ante/ante.go#L63-L64

Added lines #L63 - L64 were not covered by tests

sigGasConsumer := options.SigGasConsumer
if sigGasConsumer == nil {
Expand Down

0 comments on commit be14a97

Please sign in to comment.