martmull
2024-08-23 16:01:40 +02:00
committed by GitHub
parent ee6180a76f
commit f9af25b57e
8 changed files with 64 additions and 25 deletions

View File

@ -33,7 +33,10 @@ export const SettingsNavigationDrawerItems = () => {
const isFunctionSettingsEnabled = useIsFeatureEnabled(
'IS_FUNCTION_SETTINGS_ENABLED',
);
const isFreeAccessEnabled = useIsFeatureEnabled('IS_FREE_ACCESS_ENABLED');
const isCRMMigrationEnabled = useIsFeatureEnabled('IS_CRM_MIGRATION_ENABLED');
const isBillingPageEnabled =
billing?.isBillingEnabled && !isFreeAccessEnabled;
return (
<>
@ -84,7 +87,7 @@ export const SettingsNavigationDrawerItems = () => {
path={SettingsPath.WorkspaceMembersPage}
Icon={IconUsers}
/>
{billing?.isBillingEnabled && (
{isBillingPageEnabled && (
<SettingsNavigationDrawerItem
label="Billing"
path={SettingsPath.Billing}

View File

@ -24,7 +24,7 @@ describe('useServerlessFunctionUpdateFormState', () => {
);
useGetOneServerlessFunctionMock.useGetOneServerlessFunction.mockReturnValue(
{
serverlessFunction: { sourceCodeFullPath: undefined },
serverlessFunction: { name: 'name' },
},
);
const useGetOneServerlessFunctionSourceCodeMock = jest.requireMock(

View File

@ -7,4 +7,5 @@ export type FeatureFlagKey =
| 'IS_FUNCTION_SETTINGS_ENABLED'
| 'IS_COPILOT_ENABLED'
| 'IS_CRM_MIGRATION_ENABLED'
| 'IS_FREE_ACCESS_ENABLED'
| 'IS_MESSAGE_THREAD_SUBSCRIBER_ENABLED';