From 73464229db7e41b223ed7b008d390b471e2011bd Mon Sep 17 00:00:00 2001 From: Xiao Yijun Date: Mon, 25 Dec 2023 18:02:40 +0800 Subject: [PATCH] fix(console): correct surpass limitation check for m2m apps (#5154) --- packages/console/src/hooks/use-applications-usage.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/console/src/hooks/use-applications-usage.ts b/packages/console/src/hooks/use-applications-usage.ts index 821b5cd51..33a20319e 100644 --- a/packages/console/src/hooks/use-applications-usage.ts +++ b/packages/console/src/hooks/use-applications-usage.ts @@ -4,7 +4,7 @@ import useSWR from 'swr'; import { isCloud } from '@/consts/env'; import { TenantsContext } from '@/contexts/TenantsProvider'; -import { hasReachedQuotaLimit } from '@/utils/quota'; +import { hasReachedQuotaLimit, hasSurpassedQuotaLimit } from '@/utils/quota'; import useSubscriptionPlan from './use-subscription-plan'; @@ -40,7 +40,7 @@ const useApplicationsUsage = () => { () => Boolean( currentPlan && - hasReachedQuotaLimit({ + hasSurpassedQuotaLimit({ quotaKey: 'machineToMachineLimit', plan: currentPlan, usage: m2mAppCount,