diff --git a/build.gradle.kts b/build.gradle.kts index e0742adb3..62fe5de61 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -52,7 +52,7 @@ allprojects { } group = "exchange.dydx.abacus" -version = "1.12.29" +version = "1.12.30" repositories { google() diff --git a/src/commonMain/kotlin/exchange.dydx.abacus/state/manager/Environment.kt b/src/commonMain/kotlin/exchange.dydx.abacus/state/manager/Environment.kt index a84f3d590..06864aacf 100644 --- a/src/commonMain/kotlin/exchange.dydx.abacus/state/manager/Environment.kt +++ b/src/commonMain/kotlin/exchange.dydx.abacus/state/manager/Environment.kt @@ -552,6 +552,12 @@ data object StatsigConfig { var ff_enable_timestamp_nonce: Boolean = false } +@JsExport +@Suppress("PropertyName") +data object AutoSweepConfig { + var disable_autosweep: Boolean = false +} + @JsExport class AppSettings( val ios: AppSetting?, diff --git a/src/commonMain/kotlin/exchange.dydx.abacus/state/v2/supervisor/AccountSupervisor.kt b/src/commonMain/kotlin/exchange.dydx.abacus/state/v2/supervisor/AccountSupervisor.kt index 1bb4c1f81..c294fbf84 100644 --- a/src/commonMain/kotlin/exchange.dydx.abacus/state/v2/supervisor/AccountSupervisor.kt +++ b/src/commonMain/kotlin/exchange.dydx.abacus/state/v2/supervisor/AccountSupervisor.kt @@ -19,6 +19,7 @@ import exchange.dydx.abacus.state.app.adaptors.V4TransactionErrors import exchange.dydx.abacus.state.changes.Changes import exchange.dydx.abacus.state.changes.StateChanges import exchange.dydx.abacus.state.manager.ApiData +import exchange.dydx.abacus.state.manager.AutoSweepConfig import exchange.dydx.abacus.state.manager.BlockAndTime import exchange.dydx.abacus.state.manager.HistoricalTradingRewardsPeriod import exchange.dydx.abacus.state.manager.HumanReadableCancelAllOrdersPayload @@ -468,6 +469,9 @@ internal open class AccountSupervisor( nobleBalancesTimer = null return } + if (AutoSweepConfig.disable_autosweep) { + return + } val timer = helper.ioImplementations.timer ?: CoroutineTimer.instance nobleBalancesTimer = timer.schedule(0.0, nobleBalancePollingDuration) { diff --git a/v4_abacus.podspec b/v4_abacus.podspec index 933d5126f..eed1e4150 100644 --- a/v4_abacus.podspec +++ b/v4_abacus.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |spec| spec.name = 'v4_abacus' - spec.version = '1.12.29' + spec.version = '1.12.30' spec.homepage = 'https://github.com/dydxprotocol/v4-abacus' spec.source = { :http=> ''} spec.authors = ''