mirror of
https://github.com/bitwarden/server.git
synced 2025-04-07 05:58:13 -05:00
fix cancelled typo in areas
This commit is contained in:
parent
05b1c1cf9b
commit
0d4ac29bc7
@ -99,7 +99,7 @@ namespace Bit.Core.Models.Business
|
|||||||
PeriodEndDate = sub.CurrentPeriodEnd;
|
PeriodEndDate = sub.CurrentPeriodEnd;
|
||||||
CancelledDate = sub.CanceledAt;
|
CancelledDate = sub.CanceledAt;
|
||||||
CancelAtEndDate = sub.CancelAtPeriodEnd;
|
CancelAtEndDate = sub.CancelAtPeriodEnd;
|
||||||
Cancelled = sub.Status == "cancelled";
|
Cancelled = sub.Status == "canceled" || sub.Status == "unpaid";
|
||||||
if(sub.Items?.Data != null)
|
if(sub.Items?.Data != null)
|
||||||
{
|
{
|
||||||
Items = sub.Items.Data.Select(i => new BillingSubscriptionItem(i));
|
Items = sub.Items.Data.Select(i => new BillingSubscriptionItem(i));
|
||||||
|
@ -164,8 +164,8 @@ namespace Bit.Core.Services
|
|||||||
if(sub != null)
|
if(sub != null)
|
||||||
{
|
{
|
||||||
var cancelAtEndDate = !sub.NeverExpires.GetValueOrDefault();
|
var cancelAtEndDate = !sub.NeverExpires.GetValueOrDefault();
|
||||||
var cancelled = sub.Status == SubscriptionStatus.CANCELED;
|
var canceled = sub.Status == SubscriptionStatus.CANCELED;
|
||||||
if(!cancelled && !cancelAtEndDate && sub.NextBillingDate.HasValue)
|
if(!canceled && !cancelAtEndDate && sub.NextBillingDate.HasValue)
|
||||||
{
|
{
|
||||||
return new BillingInfo.BillingInvoice(sub);
|
return new BillingInfo.BillingInvoice(sub);
|
||||||
}
|
}
|
||||||
|
@ -193,9 +193,9 @@ namespace Bit.Core.Services
|
|||||||
throw new GatewayException("Subscription was not found.");
|
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;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user