Skip to content

Commit 846171d

Browse files
authored
fix AmountFilled in Binance user stream (#770)
- different for trade vs order
1 parent b4fda04 commit 846171d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ExchangeSharp/API/Exchanges/BinanceGroup/Models/UserDataStream.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ public ExchangeOrderResult ExchangeOrderResult
8888
Result = status,
8989
ResultCode = CurrentOrderStatus,
9090
Message = OrderRejectReason, // can use for multiple things in the future if needed
91-
Amount = CumulativeFilledQuantity,
91+
AmountFilled = TradeId != null ? LastExecutedQuantity : CumulativeFilledQuantity,
9292
Price = OrderPrice,
9393
AveragePrice = CumulativeQuoteAssetTransactedQuantity / CumulativeFilledQuantity, // Average price can be found by doing Z divided by z.
9494
OrderDate = CryptoUtility.UnixTimeStampToDateTimeMilliseconds(OrderCreationTime),

0 commit comments

Comments
 (0)