Skip to content

Commit

Permalink
Wrap tokenfactory error (#1634)
Browse files Browse the repository at this point in the history
<!-- < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < ☺
v                               ✰  Thanks for creating a PR! ✰    
v    Before smashing the submit button please review the checkboxes.
v    If a checkbox is n/a - please still include it but + a little note why
v    If your PR doesn't close an issue, that's OK!  Just remove the Closes: #XXX line!
☺ > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >  --

## What is the purpose of the change

Help improve debugging for token factory.

## Documentation and Release Note

  - Does this pull request introduce a new feature or user-facing behavior changes? (yes / no)
  - Is a relevant changelog entry added to the `Unreleased` section in `CHANGELOG.md`? (yes / no)
  - How is the feature or change documented? (not applicable   /   specification (`x/<module>/spec/`)  /  [Osmosis docs repo](https://github.com/osmosis-labs/docs)   /   not documented)
  • Loading branch information
ValarDragon authored Jun 1, 2022
1 parent 2f930cb commit 9e19d5a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion x/tokenfactory/keeper/msg_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ func (server msgServer) Mint(goCtx context.Context, msg *types.MsgMint) (*types.
// pay some extra gas cost to give a better error here.
_, denomExists := server.bankKeeper.GetDenomMetaData(ctx, msg.Amount.Denom)
if !denomExists {
return nil, types.ErrDenomDoesNotExist
return nil, types.ErrDenomDoesNotExist.Wrapf("denom: %s", msg.Amount.Denom)
}

authorityMetadata, err := server.Keeper.GetAuthorityMetadata(ctx, msg.Amount.GetDenom())
Expand Down

0 comments on commit 9e19d5a

Please sign in to comment.