remove freeAccess user logic (#9866)

closes #9763

---------

Co-authored-by: etiennejouan <jouan.etienne@gmail.com>
This commit is contained in:
Etienne
2025-01-27 17:49:16 +01:00
committed by GitHub
parent 7362558e30
commit 10476fcb01
8 changed files with 11 additions and 50 deletions

View File

@ -1,22 +1,16 @@
import { useCreateAppRouter } from '@/app/hooks/useCreateAppRouter';
import { currentUserState } from '@/auth/states/currentUserState';
import { billingState } from '@/client-config/states/billingState';
import { useIsFeatureEnabled } from '@/workspace/hooks/useIsFeatureEnabled';
import { RouterProvider } from 'react-router-dom';
import { useRecoilValue } from 'recoil';
import { FeatureFlagKey } from '~/generated/graphql';
export const AppRouter = () => {
const billing = useRecoilValue(billingState);
const isFreeAccessEnabled = useIsFeatureEnabled(
FeatureFlagKey.IsFreeAccessEnabled,
);
// We want to disable serverless function settings but keep the code for now
const isFunctionSettingsEnabled = false;
const isBillingPageEnabled =
billing?.isBillingEnabled && !isFreeAccessEnabled;
const isBillingPageEnabled = billing?.isBillingEnabled;
const currentUser = useRecoilValue(currentUserState);