mirror of
https://github.com/signalapp/Signal-Server
synced 2026-04-20 03:28:04 +01:00
Use start of subscription period as fallback timestamp
This commit is contained in:
@@ -616,8 +616,8 @@ public class StripeManager implements SubscriptionProcessorManager {
|
||||
if (invoice.getStatusTransitions().getPaidAt() != null) {
|
||||
paidAt = Instant.ofEpochSecond(invoice.getStatusTransitions().getPaidAt());
|
||||
} else {
|
||||
logger.warn("No paidAt timestamp exists for paid invoice {}, falling back to end of subscription period", invoice.getId());
|
||||
paidAt = Instant.ofEpochSecond(subscriptionLineItem.getPeriod().getEnd());
|
||||
logger.warn("No paidAt timestamp exists for paid invoice {}, falling back to start of subscription period", invoice.getId());
|
||||
paidAt = Instant.ofEpochSecond(subscriptionLineItem.getPeriod().getStart());
|
||||
}
|
||||
return getProductForPrice(subscriptionLineItem.getPrice().getId()).thenApply(product -> new ReceiptItem(
|
||||
subscriptionLineItem.getId(),
|
||||
|
||||
Reference in New Issue
Block a user