Updated on 2026-08-14

This commit is contained in:
Tangem 2020-12-18 18:11:51 +00:00
commit 7c45b7debb
2 changed files with 6 additions and 3 deletions

View file

@ -19,8 +19,11 @@ class CreateTwinWalletMiddleware {
when (action) {
is DetailsAction.CreateTwinWalletAction.ShowWarning -> {
val wallet = store.state.detailsState.wallet
val notEmpty = wallet?.recentTransactions?.isNullOrEmpty() != true ||
wallet.amounts.toSendableAmounts().isNotEmpty()
if (wallet == null) {
store.dispatch(NavigationAction.NavigateTo(AppScreen.CreateTwinWalletWarning))
return
}
val notEmpty = wallet.recentTransactions.isNotEmpty() || wallet.amounts.toSendableAmounts().isNotEmpty()
if (notEmpty) {
store.dispatch(DetailsAction.CreateTwinWalletAction.NotEmpty)
} else {

View file

@ -197,7 +197,7 @@
<string name="initial_message_scan_header">Tap to scan</string>
<string name="initial_message_tap_header">Tap the card</string>
<string name="details_notification_erase_wallet_not_possible">You balance on this wallet is not zero, or you have unconfirmed transactions</string>
<string name="details_notification_erase_wallet_not_possible">Your balance on this wallet is not zero, or you have unconfirmed transactions</string>
<string name="details_notification_security_option_already_active">This is the currently active option</string>