File tree Expand file tree Collapse file tree
app/src/main/java/to/bitkit/ui/screens/transfer Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -75,6 +75,7 @@ fun SpendingAdvancedScreen(
7575
7676 val transferValues by viewModel.transferValues.collectAsStateWithLifecycle()
7777 val currentMaxLspBalance by rememberUpdatedState(transferValues.maxLspBalance)
78+ val currentCurrencies by rememberUpdatedState(currencies)
7879
7980 LaunchedEffect (order.clientBalanceSat) {
8081 viewModel.updateTransferValues(order.clientBalanceSat)
@@ -113,7 +114,7 @@ fun SpendingAdvancedScreen(
113114 amountInputViewModel.effect.collect {
114115 when (it) {
115116 AmountInputEffect .MaxExceeded -> {
116- amountInputViewModel.setSats(currentMaxLspBalance.toLong(), currencies )
117+ amountInputViewModel.setSats(currentMaxLspBalance.toLong(), currentCurrencies )
117118 app.toast(
118119 type = Toast .ToastType .WARNING ,
119120 title = context.getString(R .string.lightning__spending_advanced__error_max__title),
Original file line number Diff line number Diff line change @@ -73,6 +73,7 @@ fun SpendingAmountScreen(
7373 val amountUiState by amountInputViewModel.uiState.collectAsStateWithLifecycle()
7474 val context = LocalContext .current
7575 val currentMaxAllowedToSend by rememberUpdatedState(uiState.maxAllowedToSend)
76+ val currentCurrencies by rememberUpdatedState(currencies)
7677
7778 LaunchedEffect (isOffline) {
7879 viewModel.updateLimits()
@@ -92,7 +93,7 @@ fun SpendingAmountScreen(
9293 amountInputViewModel.effect.collect {
9394 when (it) {
9495 AmountInputEffect .MaxExceeded -> {
95- amountInputViewModel.setSats(currentMaxAllowedToSend, currencies )
96+ amountInputViewModel.setSats(currentMaxAllowedToSend, currentCurrencies )
9697 toast(
9798 context.getString(R .string.lightning__spending_amount__error_max__title),
9899 context.getString(R .string.lightning__spending_amount__error_max__description)
You can’t perform that action at this time.
0 commit comments