diff --git a/src/Core/Models/Business/BillingInfo.cs b/src/Core/Models/Business/BillingInfo.cs index 64a2ea128..1e1d5d9bf 100644 --- a/src/Core/Models/Business/BillingInfo.cs +++ b/src/Core/Models/Business/BillingInfo.cs @@ -99,7 +99,7 @@ namespace Bit.Core.Models.Business PeriodEndDate = sub.CurrentPeriodEnd; CancelledDate = sub.CanceledAt; CancelAtEndDate = sub.CancelAtPeriodEnd; - Cancelled = sub.Status == "cancelled"; + Cancelled = sub.Status == "canceled" || sub.Status == "unpaid"; if(sub.Items?.Data != null) { Items = sub.Items.Data.Select(i => new BillingSubscriptionItem(i)); diff --git a/src/Core/Services/Implementations/BraintreePaymentService.cs b/src/Core/Services/Implementations/BraintreePaymentService.cs index 78d6fc601..43ec65ae0 100644 --- a/src/Core/Services/Implementations/BraintreePaymentService.cs +++ b/src/Core/Services/Implementations/BraintreePaymentService.cs @@ -164,8 +164,8 @@ namespace Bit.Core.Services if(sub != null) { var cancelAtEndDate = !sub.NeverExpires.GetValueOrDefault(); - var cancelled = sub.Status == SubscriptionStatus.CANCELED; - if(!cancelled && !cancelAtEndDate && sub.NextBillingDate.HasValue) + var canceled = sub.Status == SubscriptionStatus.CANCELED; + if(!canceled && !cancelAtEndDate && sub.NextBillingDate.HasValue) { return new BillingInfo.BillingInvoice(sub); } diff --git a/src/Core/Services/Implementations/StripePaymentService.cs b/src/Core/Services/Implementations/StripePaymentService.cs index ddf6c04f1..8f74177f5 100644 --- a/src/Core/Services/Implementations/StripePaymentService.cs +++ b/src/Core/Services/Implementations/StripePaymentService.cs @@ -193,9 +193,9 @@ namespace Bit.Core.Services throw new GatewayException("Subscription was not found."); } - if(sub.CanceledAt.HasValue || sub.Status == "cancelled") + if(sub.CanceledAt.HasValue || sub.Status == "canceled" || sub.Status == "unpaid") { - // Already cancelled + // Already canceled return; }