Skip to content

Commit

Permalink
add test diff
Browse files Browse the repository at this point in the history
  • Loading branch information
matteyu committed Mar 20, 2020
1 parent 3450307 commit 148c640
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion x/crud/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func handleMsgCreate(ctx sdk.Context, keeper keeper.IKeeper, msg types.MsgCreate
if len(msg.UUID) == 0 || len(msg.Key) == 0 || msg.Owner.Empty() {
return nil, sdkerrors.Wrap(sdkerrors.ErrInvalidRequest, "Invalid message")
}

//test
if !keeper.GetValue(ctx, keeper.GetKVStore(ctx), msg.UUID, msg.Key).Owner.Empty() {
return nil, sdkerrors.Wrap(sdkerrors.ErrInvalidRequest, "Key already exists")
}
Expand Down

0 comments on commit 148c640

Please sign in to comment.