Skip to content

Commit

Permalink
Fix label validation error (#1555)
Browse files Browse the repository at this point in the history
  • Loading branch information
pinosu authored Aug 17, 2023
1 parent 33df4ae commit 08c517b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions x/wasm/types/tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ func (msg MsgInstantiateContract) ValidateBasic() error {
}

if err := ValidateLabel(msg.Label); err != nil {
return errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "label is required")
return errorsmod.Wrap(err, "label")
}

if !msg.Funds.IsValid() {
Expand Down Expand Up @@ -365,7 +365,7 @@ func (msg MsgInstantiateContract2) ValidateBasic() error {
}

if err := ValidateLabel(msg.Label); err != nil {
return errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "label is required")
return errorsmod.Wrap(err, "label")
}

if !msg.Funds.IsValid() {
Expand Down Expand Up @@ -584,7 +584,7 @@ func (msg MsgStoreAndInstantiateContract) ValidateBasic() error {
}

if err := ValidateLabel(msg.Label); err != nil {
return errorsmod.Wrap(sdkerrors.ErrInvalidRequest, "label is required")
return errorsmod.Wrap(err, "label")
}

if !msg.Funds.IsValid() {
Expand Down

0 comments on commit 08c517b

Please sign in to comment.