Skip to content

Commit

Permalink
refactor(x/validate): add nil protection (#22902)
Browse files Browse the repository at this point in the history
  • Loading branch information
aljo242 authored Dec 16, 2024
1 parent c6b1bdc commit f14cbd2
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions x/validate/module.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@ func (a AppModule) TxValidator(ctx context.Context, tx transaction.Tx) error {
}
}

if a.feeTxValidator == nil {
panic("feeTxValidator cannot be nil")
}

if err := a.feeTxValidator.ValidateTx(ctx, tx); err != nil {
return err
}
Expand Down

0 comments on commit f14cbd2

Please sign in to comment.