Skip to content

Commit

Permalink
fix handle mini list
Browse files Browse the repository at this point in the history
  • Loading branch information
Erheng Lu committed Jun 22, 2020
1 parent c653682 commit f375c83
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/dex/list/handler_mini.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ func handleListMini(ctx sdk.Context, dexKeeper *order.DexKeeper, tokenMapper tok
if !baseToken.IsOwner(msg.From) && !quoteToken.IsOwner(msg.From) {
return sdk.ErrUnauthorized("only the owner of the base asset or quote asset can list the trading pair").Result()
}

dexKeeper.CleanRecentPrice(msg.BaseAssetSymbol, msg.QuoteAssetSymbol)
lotSize := dexKeeper.DetermineLotSize(msg.BaseAssetSymbol, msg.QuoteAssetSymbol, msg.InitPrice)
pair := types.NewTradingPairWithLotSize(msg.BaseAssetSymbol, msg.QuoteAssetSymbol, msg.InitPrice, lotSize)
err = dexKeeper.PairMapper.AddTradingPair(ctx, pair)
Expand Down

0 comments on commit f375c83

Please sign in to comment.