1
0
mirror of https://github.com/bitwarden/server.git synced 2025-07-11 21:03:47 -05:00

Updated Stripe API SDK version to 36.9.0

This commit is contained in:
Chad Scharf
2020-05-08 10:15:48 -04:00
parent 3c5cd0ffb2
commit 9a2d8e96e4
3 changed files with 74 additions and 72 deletions

View File

@ -339,7 +339,7 @@ namespace Bit.Core.Services
.Select(i => new InvoiceSubscriptionItemOptions
{
Id = i.Id,
PlanId = i.Plan.Id,
Plan = i.Plan.Id,
Quantity = i.Quantity,
}).ToList();
@ -347,16 +347,16 @@ namespace Bit.Core.Services
{
subItemOptions.Add(new InvoiceSubscriptionItemOptions
{
PlanId = plan.StripeSeatPlanId,
Plan = plan.StripeSeatPlanId,
Quantity = additionalSeats,
});
subUpdateAction = (prorate) => subscriptionItemService.CreateAsync(
new SubscriptionItemCreateOptions
{
PlanId = plan.StripeSeatPlanId,
Plan = plan.StripeSeatPlanId,
Quantity = additionalSeats,
Prorate = prorate,
SubscriptionId = sub.Id
Subscription = sub.Id
});
}
else if (additionalSeats > 0 && seatItem != null)
@ -364,13 +364,13 @@ namespace Bit.Core.Services
subItemOptions.Add(new InvoiceSubscriptionItemOptions
{
Id = seatItem.Id,
PlanId = plan.StripeSeatPlanId,
Plan = plan.StripeSeatPlanId,
Quantity = additionalSeats,
});
subUpdateAction = (prorate) => subscriptionItemService.UpdateAsync(seatItem.Id,
new SubscriptionItemUpdateOptions
{
PlanId = plan.StripeSeatPlanId,
Plan = plan.StripeSeatPlanId,
Quantity = additionalSeats,
Prorate = prorate
});
@ -382,7 +382,8 @@ namespace Bit.Core.Services
Id = seatItem.Id,
Deleted = true
});
subUpdateAction = (prorate) => subscriptionItemService.DeleteAsync(seatItem.Id);
subUpdateAction = (prorate) => subscriptionItemService.DeleteAsync(seatItem.Id,
new SubscriptionItemDeleteOptions());
}
string paymentIntentClientSecret = null;