diff --git a/src/lib/stores/billing.ts b/src/lib/stores/billing.ts index f0c0aec77..f41395517 100644 --- a/src/lib/stores/billing.ts +++ b/src/lib/stores/billing.ts @@ -142,9 +142,10 @@ export function planSupportsSoc2( return false; } - // no SOC-2 entitlement exists on the plan model, so infer it: Scale is the - // lowest group that advertises SOC-2, and contract plans sit above it. - return planHasGroup(billingPlan, BillingPlanGroup.Scale) || billingPlan.selfService === false; + // no SOC-2 entitlement exists on the plan model, so key off a real API field + // instead of guessing: SOC-2 is only offered on negotiated/custom contracts, + // never on a self-service plan (including self-service Scale). + return billingPlan.selfService === false; } export function canUpgrade( diff --git a/src/routes/(console)/organization-[organization]/settings/Soc2.svelte b/src/routes/(console)/organization-[organization]/settings/Soc2.svelte index 8a63463e4..7571515c6 100644 --- a/src/routes/(console)/organization-[organization]/settings/Soc2.svelte +++ b/src/routes/(console)/organization-[organization]/settings/Soc2.svelte @@ -2,9 +2,9 @@ import { Box, CardGrid } from '$lib/components'; import { Button } from '$lib/elements/forms'; import Soc2Modal from './Soc2Modal.svelte'; - import { getBasePlanFromGroup, getChangePlanUrl, planSupportsSoc2 } from '$lib/stores/billing'; - import { currentPlan, organization } from '$lib/stores/organization'; - import { BillingPlanGroup, type Models } from '@appwrite.io/console'; + import { planSupportsSoc2 } from '$lib/stores/billing'; + import { currentPlan } from '$lib/stores/organization'; + import type { Models } from '@appwrite.io/console'; let { locale, @@ -17,7 +17,6 @@ let show = $state(false); const supportsSoc2 = $derived(planSupportsSoc2($currentPlan)); - const upgradePlanName = $derived(getBasePlanFromGroup(BillingPlanGroup.Scale)?.name); @@ -44,18 +43,16 @@ {:else}

- SOC-2 is not available on your current plan.{upgradePlanName - ? ` Upgrade to ${upgradePlanName} to request a SOC-2 report for your organization.` - : ''} + SOC-2 reports are only available on an Enterprise contract. Contact our sales + team to discuss upgrading your organization.

- {#if upgradePlanName} - - {/if} + {/if}