Skip to content

Commit 6e3b2e3

Browse files
committed
fix: remove transaction replaced toast
1 parent eec2635 commit 6e3b2e3

File tree

1 file changed

+0
-20
lines changed

1 file changed

+0
-20
lines changed

app/src/main/java/to/bitkit/viewmodels/AppViewModel.kt

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,6 @@ class AppViewModel @Inject constructor(
312312

313313
private suspend fun handleOnchainTransactionReplaced(event: Event.OnchainTransactionReplaced) {
314314
activityRepo.handleOnchainTransactionReplaced(event.txid, event.conflicts)
315-
notifyTransactionReplaced(event)
316315
}
317316

318317
private suspend fun handlePaymentFailed(event: Event.PaymentFailed) {
@@ -397,25 +396,6 @@ class AppViewModel @Inject constructor(
397396
testTag = "TransactionUnconfirmedToast",
398397
)
399398

400-
private suspend fun notifyTransactionReplaced(event: Event.OnchainTransactionReplaced) {
401-
val isReceive = activityRepo.isReceivedTransaction(event.txid)
402-
toast(
403-
type = Toast.ToastType.INFO,
404-
title = when (isReceive) {
405-
true -> R.string.wallet__toast_received_transaction_replaced_title
406-
else -> R.string.wallet__toast_transaction_replaced_title
407-
}.let { context.getString(it) },
408-
description = when (isReceive) {
409-
true -> R.string.wallet__toast_received_transaction_replaced_description
410-
else -> R.string.wallet__toast_transaction_replaced_description
411-
}.let { context.getString(it) },
412-
testTag = when (isReceive) {
413-
true -> "ReceivedTransactionReplacedToast"
414-
else -> "TransactionReplacedToast"
415-
},
416-
)
417-
}
418-
419399
private fun notifyPaymentFailed() = toast(
420400
type = Toast.ToastType.ERROR,
421401
title = context.getString(R.string.wallet__toast_payment_failed_title),

0 commit comments

Comments
 (0)