mirror of
https://github.com/bitwarden/server.git
synced 2024-12-23 17:07:42 +01:00
Fix the Bug for org without subscription (#4213)
Signed-off-by: Cy Okeke <cokeke@bitwarden.com>
This commit is contained in:
parent
d9aa27d4cb
commit
e0f7d212c8
@ -436,12 +436,16 @@ public class ProviderService : IProviderService
|
||||
return;
|
||||
}
|
||||
|
||||
var subscriptionItem = await GetSubscriptionItemAsync(organization.GatewaySubscriptionId, GetStripeSeatPlanId(organization.PlanType));
|
||||
if (!string.IsNullOrWhiteSpace(organization.GatewaySubscriptionId))
|
||||
{
|
||||
var subscriptionItem = await GetSubscriptionItemAsync(organization.GatewaySubscriptionId,
|
||||
GetStripeSeatPlanId(organization.PlanType));
|
||||
var extractedPlanType = PlanTypeMappings(organization);
|
||||
if (subscriptionItem != null)
|
||||
{
|
||||
await UpdateSubscriptionAsync(subscriptionItem, GetStripeSeatPlanId(extractedPlanType), organization);
|
||||
}
|
||||
}
|
||||
|
||||
await _organizationRepository.UpsertAsync(organization);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user