fix : removed the unnecessary usage of ErrInvalidMsg (#1311)

* feat:added a new error type

* feat:added a new error type

* fix: removed unnecessary usage of error type ErrInvalidMsg

---------

Co-authored-by: Vishal <kannavish329@gamil.com>
This commit is contained in:
vishal-kanna
2023-04-04 14:44:57 +05:30
committed by GitHub
parent b33c38c811
commit 4c906d5a53

View File

@@ -262,7 +262,7 @@ func (msg MsgUpdateAdmin) ValidateBasic() error {
return errorsmod.Wrap(err, "new admin")
}
if strings.EqualFold(msg.Sender, msg.NewAdmin) {
return errorsmod.Wrap(ErrInvalidMsg, "new admin is the same as the old")
return errorsmod.Wrap(ErrInvalid, "new admin is the same as the old")
}
return nil
}