diff --git a/python/ccxt/bitmex.py b/python/ccxt/bitmex.py index 7ed0053384bb..4a269ff3651e 100644 --- a/python/ccxt/bitmex.py +++ b/python/ccxt/bitmex.py @@ -478,7 +478,7 @@ def parse_ledger_entry(self, item, currency=None): amount = abs(amount) else: direction = 'in' - status = self.parse_transaction_status(item, 'transactStatus') + status = self.parse_transaction_status(self.safe_string(item, 'transactStatus')) return { 'info': item, 'id': id, @@ -548,7 +548,7 @@ def fetch_transactions(self, code=None, since=None, limit=None, params={}): if limit is not None: request['count'] = limit response = self.privateGetUserWalletHistory(self.extend(request, params)) - transactions = self.filter_by_array(response, ['Withdrawal', 'Deposit'], False) + transactions = self.filter_by_array(response, 'transactType', ['Withdrawal', 'Deposit'], False) currency = None if code is not None: currency = self.currency(code)