Update order_selection logic

This commit is contained in:
Matthias 2022-02-05 10:12:03 +01:00
parent 9bf86bbe27
commit 808cefe526

View File

@ -650,9 +650,9 @@ class LocalTrade():
Finds order object by Order id. Finds order object by Order id.
:param order_id: Exchange order id :param order_id: Exchange order id
""" """
orders = [o for o in self.orders if o.order_id == order_id] for o in self.orders:
if orders: if o.order_id == order_id:
return orders[0] return o
return None return None
def select_order( def select_order(