mirror of
https://github.com/bitwarden/server.git
synced 2025-07-03 17:12:49 -05:00
[PM-11730] Remove feature flag: AC-2476-deprecate-stripe-sources-api (#5201)
* Removed feature flag * Run dotnet format * Fix integration tests
This commit is contained in:
@ -224,27 +224,8 @@ public class UpgradeOrganizationPlanCommand : IUpgradeOrganizationPlanCommand
|
||||
|
||||
if (string.IsNullOrWhiteSpace(organization.GatewaySubscriptionId))
|
||||
{
|
||||
if (_featureService.IsEnabled(FeatureFlagKeys.AC2476_DeprecateStripeSourcesAPI))
|
||||
{
|
||||
var sale = OrganizationSale.From(organization, upgrade);
|
||||
await _organizationBillingService.Finalize(sale);
|
||||
}
|
||||
else
|
||||
{
|
||||
try
|
||||
{
|
||||
paymentIntentClientSecret = await _paymentService.UpgradeFreeOrganizationAsync(organization,
|
||||
newPlan, upgrade);
|
||||
success = string.IsNullOrWhiteSpace(paymentIntentClientSecret);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _paymentService.CancelAndRecoverChargesAsync(organization);
|
||||
organization.GatewayCustomerId = null;
|
||||
await _organizationService.ReplaceAndUpdateCacheAsync(organization);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
var sale = OrganizationSale.From(organization, upgrade);
|
||||
await _organizationBillingService.Finalize(sale);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Reference in New Issue
Block a user