From 4fda89ddf48bb480aac87b2731e93c421cf9a9c3 Mon Sep 17 00:00:00 2001 From: Tyler Date: Tue, 12 Nov 2024 13:59:08 -0500 Subject: [PATCH] fix --- .../state/v2/supervisor/SubaccountTransactionSupervisor.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/commonMain/kotlin/exchange.dydx.abacus/state/v2/supervisor/SubaccountTransactionSupervisor.kt b/src/commonMain/kotlin/exchange.dydx.abacus/state/v2/supervisor/SubaccountTransactionSupervisor.kt index 5e3816de3..642f60f23 100644 --- a/src/commonMain/kotlin/exchange.dydx.abacus/state/v2/supervisor/SubaccountTransactionSupervisor.kt +++ b/src/commonMain/kotlin/exchange.dydx.abacus/state/v2/supervisor/SubaccountTransactionSupervisor.kt @@ -291,7 +291,7 @@ internal class SubaccountTransactionSupervisor( internal fun cancelTriggerOrdersWithClosedOrFlippedPositions() { val subaccount = stateMachine.state?.subaccount(subaccountNumber) ?: return - if (stateMachine.state?.marketsSummary?.marketIds()?.isEmpty() != false) return + if (stateMachine.state?.marketsSummary?.marketIds().isNullOrEmpty()) return val cancelableTriggerOrders = subaccount.orders?.filter { order -> val isConditionalOrder = order.orderFlags == CONDITIONAL_ORDER_FLAGS