Skip to content

Commit

Permalink
Fixed Shared balance subscription also sending funding balances
Browse files Browse the repository at this point in the history
  • Loading branch information
JKorf committed Dec 4, 2024
1 parent 8a14871 commit 09addf2
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ async Task<ExchangeResult<UpdateSubscription>> IBalanceSocketClient.SubscribeToB
if (update.UpdateType == SocketUpdateType.Snapshot)
return;

handler(update.AsExchangeEvent<IEnumerable<SharedBalance>>(Exchange, update.Data.Select(x => new SharedBalance(x.Asset, x.Available ?? x.Total, x.Total)).ToArray()));
handler(update.AsExchangeEvent<IEnumerable<SharedBalance>>(Exchange, update.Data.Where(x => x.Type == Enums.WalletType.Exchange).Select(x => new SharedBalance(x.Asset, x.Available ?? x.Total, x.Total)).ToArray()));
},
ct: ct).ConfigureAwait(false);

Expand Down

0 comments on commit 09addf2

Please sign in to comment.