Revert unintended double-call of amount conversion

This commit is contained in:
Matthias
2022-01-02 13:11:29 +01:00
parent 67a5739501
commit 7f88f9bf27
2 changed files with 4 additions and 8 deletions

View File

@@ -1288,13 +1288,9 @@ class Exchange:
# since needs to be int in milliseconds
_params = params if params else {}
my_trades = self._api.fetch_my_trades(
pair,
int((since.replace(tzinfo=timezone.utc).timestamp() - 5) * 1000),
params=_params
)
matched_trades = self._trades_contracts_to_amount(
trades=[trade for trade in my_trades if trade['order'] == order_id]
)
pair, int((since.replace(tzinfo=timezone.utc).timestamp() - 5) * 1000),
params=_params)
matched_trades = [trade for trade in my_trades if trade['order'] == order_id]
self._log_exchange_response('get_trades_for_order', matched_trades)