Remove a couple unnecessary backup TODOs.

This commit is contained in:
Alex Hart
2024-11-04 09:33:45 -04:00
parent 19c3075bc6
commit ec03b11230
2 changed files with 3 additions and 3 deletions

View File

@@ -60,7 +60,6 @@ class GatewaySelectorBottomSheet : DSLSettingsBottomSheetFragment() {
private fun getConfiguration(state: GatewaySelectorState): DSLConfiguration {
return configure {
// TODO [backups] -- No badge on message backups.
customPref(
BadgeDisplay112.Model(
badge = state.inAppPayment.data.badge!!.let { Badges.fromDatabaseBadge(it) },
@@ -209,7 +208,7 @@ class GatewaySelectorBottomSheet : DSLSettingsBottomSheetFragment() {
fun DSLConfiguration.presentTitleAndSubtitle(context: Context, inAppPayment: InAppPaymentTable.InAppPayment) {
when (inAppPayment.type) {
InAppPaymentType.UNKNOWN -> error("Unsupported type UNKNOWN")
InAppPaymentType.RECURRING_BACKUP -> error("This type is not supported") // TODO [backups] necessary?
InAppPaymentType.RECURRING_BACKUP -> error("This type is not supported")
InAppPaymentType.RECURRING_DONATION -> presentMonthlyText(context, inAppPayment)
InAppPaymentType.ONE_TIME_DONATION -> presentOneTimeText(context, inAppPayment)
InAppPaymentType.ONE_TIME_GIFT -> presentGiftText(context, inAppPayment)

View File

@@ -23,6 +23,7 @@ import org.signal.core.util.logging.Log
import org.signal.donations.InAppPaymentType
import org.thoughtcrime.securesms.R
import org.thoughtcrime.securesms.components.ViewBinderDelegate
import org.thoughtcrime.securesms.components.settings.app.subscription.InAppPaymentsRepository.requireSubscriberType
import org.thoughtcrime.securesms.components.settings.app.subscription.InAppPaymentsRepository.toErrorSource
import org.thoughtcrime.securesms.components.settings.app.subscription.donate.InAppPaymentProcessorAction
import org.thoughtcrime.securesms.components.settings.app.subscription.donate.InAppPaymentProcessorActionResult
@@ -70,7 +71,7 @@ class PayPalPaymentInProgressFragment : DialogFragment(R.layout.donation_in_prog
}
InAppPaymentProcessorAction.CANCEL_SUBSCRIPTION -> {
viewModel.cancelSubscription(InAppPaymentSubscriberRecord.Type.DONATION) // TODO [backups] Remove hardcode
viewModel.cancelSubscription(args.inAppPaymentType.requireSubscriberType())
}
}
}