From 63b65fbfaacd481915707c79f40754f272739eb2 Mon Sep 17 00:00:00 2001 From: Vojtech Suchy Date: Thu, 28 Nov 2024 09:23:04 +0100 Subject: CODEFIX-214 Allow admins to hide the AI CodeFix feature --- .../src/main/js/apps/settings/components/AllCategoriesList.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'server/sonar-web/src/main/js/apps') diff --git a/server/sonar-web/src/main/js/apps/settings/components/AllCategoriesList.tsx b/server/sonar-web/src/main/js/apps/settings/components/AllCategoriesList.tsx index 95bd8a9344f..15b4661c0d6 100644 --- a/server/sonar-web/src/main/js/apps/settings/components/AllCategoriesList.tsx +++ b/server/sonar-web/src/main/js/apps/settings/components/AllCategoriesList.tsx @@ -29,7 +29,7 @@ import { translate } from '../../../helpers/l10n'; import { getGlobalSettingsUrl, getProjectSettingsUrl } from '../../../helpers/urls'; import { Feature } from '../../../types/features'; import { Component } from '../../../types/types'; -import { CATEGORY_OVERRIDES } from '../constants'; +import { AI_CODE_FIX_CATEGORY, CATEGORY_OVERRIDES } from '../constants'; import { getCategoryName } from '../utils'; import { ADDITIONAL_CATEGORIES } from './AdditionalCategories'; @@ -74,7 +74,7 @@ function CategoriesList(props: Readonly) { c.displayTab && availableForCurrentMenu && (props.hasFeature(Feature.BranchSupport) || !c.requiresBranchSupport) && - (props.hasFeature(Feature.FixSuggestions) || c.key !== 'codefix') + (props.hasFeature(Feature.FixSuggestions) || c.key !== AI_CODE_FIX_CATEGORY) ); }), ); -- cgit v1.2.3