mirror of
https://github.com/signalapp/Signal-Server
synced 2026-04-20 23:08:01 +01:00
Add failure information for the latest charge on a subscription
This commit is contained in:
@@ -245,8 +245,12 @@ public class StripeManager {
|
||||
|
||||
public CompletableFuture<Subscription> getSubscription(String subscriptionId) {
|
||||
return CompletableFuture.supplyAsync(() -> {
|
||||
SubscriptionRetrieveParams params = SubscriptionRetrieveParams.builder()
|
||||
.addExpand("latest_invoice")
|
||||
.addExpand("latest_invoice.charge")
|
||||
.build();
|
||||
try {
|
||||
return Subscription.retrieve(subscriptionId, commonOptions());
|
||||
return Subscription.retrieve(subscriptionId, params, commonOptions());
|
||||
} catch (StripeException e) {
|
||||
throw new CompletionException(e);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user