Pass in days since last backup to alert sheet.

This commit is contained in:
Alex Hart
2024-11-06 12:46:41 -04:00
committed by Greyson Parrelli
parent c85a28af92
commit 35b80be8c8
4 changed files with 27 additions and 15 deletions

View File

@@ -134,7 +134,7 @@ class InAppPaymentsBottomSheetDelegate(
}.subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread()).subscribeBy { inAppPayments ->
for (payment in inAppPayments) {
if (isPaymentProcessingError(payment.state, payment.data)) {
BackupAlertBottomSheet.create(BackupAlert.CouldNotCompleteBackup).show(fragmentManager, null)
BackupAlertBottomSheet.create(BackupAlert.CouldNotCompleteBackup(daysSinceLastBackup = SignalStore.backup.daysSinceLastBackup)).show(fragmentManager, null)
} else if (isUnexpectedCancellation(payment.state, payment.data)) {
BackupAlertBottomSheet.create(BackupAlert.MediaBackupsAreOff).show(fragmentManager, null)
}