mirror of
https://github.com/bitwarden/server.git
synced 2025-04-08 14:38:15 -05:00
custom plans with expiration are not trials
This commit is contained in:
parent
88c35f9f86
commit
8c32765f4c
@ -41,8 +41,16 @@ namespace Bit.Core.Models.Business
|
|||||||
|
|
||||||
if(billingInfo?.Subscription == null)
|
if(billingInfo?.Subscription == null)
|
||||||
{
|
{
|
||||||
Expires = Refresh = Issued.AddDays(7);
|
if(org.PlanType == PlanType.Custom && org.ExpirationDate.HasValue)
|
||||||
Trial = true;
|
{
|
||||||
|
Expires = Refresh = org.ExpirationDate.Value;
|
||||||
|
Trial = false;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Expires = Refresh = Issued.AddDays(7);
|
||||||
|
Trial = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if(billingInfo.Subscription.TrialEndDate.HasValue &&
|
else if(billingInfo.Subscription.TrialEndDate.HasValue &&
|
||||||
billingInfo.Subscription.TrialEndDate.Value > DateTime.UtcNow)
|
billingInfo.Subscription.TrialEndDate.Value > DateTime.UtcNow)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user