The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
Fixes calculation for total_egress_modified
Terry Sutton31f889734d73
diff --git a/studio/components/interfaces/Billing/Subscription/Subscription.tsx b/studio/components/interfaces/Billing/Subscription/Subscription.tsxindex 2c1dcb66f09..c56b86c5677 100644--- a/studio/components/interfaces/Billing/Subscription/Subscription.tsx+++ b/studio/components/interfaces/Billing/Subscription/Subscription.tsx@@ -3,11 +3,9 @@ import dayjs from 'dayjs'import { sum } from 'lodash'import { useRouter } from 'next/router'import { Loading, Button } from '@supabase/ui'-import { Dictionary } from '@supabase/grid'-import { formatBytes } from 'lib/helpers'import { STRIPE_PRODUCT_IDS } from 'lib/constants'-import { useStore, useSubscriptionStats } from 'hooks'+import { useStore } from 'hooks'import CostBreakdownRow from './CostBreakdownRow'import { StripeSubscription } from './Subscription.types'import { deriveFeatureCost, deriveProductCost } from '../PAYGUsage/PAYGUsage.utils'diff --git a/studio/hooks/queries/useProjectPaygStatistics.ts b/studio/hooks/queries/useProjectPaygStatistics.tsindex 37b11a69ec5..ee4507ff5e4 100644--- a/studio/hooks/queries/useProjectPaygStatistics.ts+++ b/studio/hooks/queries/useProjectPaygStatistics.ts@@ -50,7 +50,7 @@ function getPaygStats(data: any): PaygStats {let dataModified: any = []data.map((x: any) => {- dataModified.push({ ...x, total_egress_modified: x.total_egress == undefined ? 0 : x.total_egress - x.total_storage_egress == undefined ? 0 : x.total_storage_egress })+ dataModified.push({ ...x, total_egress_modified: (x.total_egress == undefined ? 0 : x.total_egress) - (x.total_storage_egress == undefined ? 0 : x.total_storage_egress) })})chargeableProducts.forEach((product) => {@@ -73,5 +73,6 @@ function getPaygStats(data: any): PaygStats {}})})+return paygStats}