Merge pull request #126 from jnlin/fix/pnl-amount

fix(max): use global trade side here, not string
This commit is contained in:
Yo-An Lin 2021-02-07 16:43:20 +08:00 committed by GitHub
commit 78750c6e48

View File

@ -194,7 +194,7 @@ func convertWebSocketTrade(t max.TradeUpdate) (*types.Trade, error) {
Price: price,
Quantity: quantity,
Side: side,
IsBuyer: side == "bid" || side == "buy",
IsBuyer: side == types.SideTypeBuy,
IsMaker: t.Maker,
Fee: fee,
FeeCurrency: toGlobalCurrency(t.FeeCurrency),