Skip to content

Commit

Permalink
Fix market.accounttrades #169
Browse files Browse the repository at this point in the history
  • Loading branch information
xeroc committed Mar 25, 2019
1 parent 79b5a96 commit 72df3c1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion bitshares/price.py
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,11 @@ def __init__(self, order, **kwargs):
elif isinstance(order, dict):
# filled orders from account history
if "op" in order:
order = order["op"][1]
if isinstance(order["op"], (list, set)):
order = order["op"][1]
elif isinstance(order["op"], dict):
order = order["op"]

base_asset = kwargs.get("base_asset", order["receives"]["asset_id"])
Price.__init__(self, order, base_asset=base_asset)

Expand Down

0 comments on commit 72df3c1

Please sign in to comment.