Skip to content

Commit

Permalink
add amount validator for fund community pool (#190)
Browse files Browse the repository at this point in the history
  • Loading branch information
beer-1 authored May 31, 2024
1 parent 9c8b993 commit 85707ca
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions x/distribution/keeper/msg_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,9 @@ func (k msgServer) WithdrawValidatorCommission(ctx context.Context, msg *types.M

func (k msgServer) FundCommunityPool(ctx context.Context, msg *types.MsgFundCommunityPool) (*types.MsgFundCommunityPoolResponse, error) {
defer telemetry.MeasureSince(time.Now(), "distribution", "msg", "fund-community-pool")
if err := msg.Amount.Validate(); err != nil {
return nil, err
}

depositor, err := k.authKeeper.AddressCodec().StringToBytes(msg.Depositor)
if err != nil {
Expand Down

0 comments on commit 85707ca

Please sign in to comment.