Donations logs.

This commit is contained in:
Alex Hart 2022-03-21 10:07:20 -03:00 committed by Greyson Parrelli
parent 5774771ea6
commit c0f843061e
2 changed files with 5 additions and 0 deletions

View file

@ -364,6 +364,10 @@ public class ConversationListFragment extends MainFragment implements ActionMode
} else if (unexpectedSubscriptionCancellation != null && !SignalStore.donationsValues().isUserManuallyCancelled() && SignalStore.donationsValues().getShowCantProcessDialog()) {
Log.w(TAG, "Displaying bottom sheet for unexpected cancellation: " + unexpectedSubscriptionCancellation, true);
new CantProcessSubscriptionPaymentBottomSheetDialogFragment().show(getChildFragmentManager(), BottomSheetUtil.STANDARD_BOTTOM_SHEET_FRAGMENT_TAG);
} else if (unexpectedSubscriptionCancellation != null && SignalStore.donationsValues().isUserManuallyCancelled()) {
Log.w(TAG, "Unexpected cancellation detected but not displaying dialog because user manually cancelled their subscription: " + unexpectedSubscriptionCancellation, true);
} else if (unexpectedSubscriptionCancellation != null && !SignalStore.donationsValues().getShowCantProcessDialog()) {
Log.w(TAG, "Unexpected cancellation detected but not displaying dialog because user has silenced it.", true);
}
}

View file

@ -116,6 +116,7 @@ internal class DonationsValues internal constructor(store: KeyValueStore) : Sign
}
fun setSubscriber(subscriber: Subscriber) {
Log.i(TAG, "Setting subscriber for currency ${subscriber.currencyCode}", Exception(), true)
val currencyCode = subscriber.currencyCode
store.beginWrite()
.putBlob("$KEY_SUBSCRIBER_ID_PREFIX$currencyCode", subscriber.subscriberId.bytes)