@@ -34,7 +34,7 @@ import Navigation from '@libs/Navigation/Navigation';
3434import type { PlatformStackScreenProps } from '@libs/Navigation/PlatformStackNavigation/types' ;
3535import { isDisablingOrDeletingLastEnabledCategory } from '@libs/OptionsListUtils' ;
3636import { getPersonalDetailByEmail } from '@libs/PersonalDetailsUtils' ;
37- import { getWorkflowApprovalsUnavailable , hasTags , isControlPolicy } from '@libs/PolicyUtils' ;
37+ import { getWorkflowApprovalsUnavailable , hasTags , isAttendeeTrackingEnabled , isControlPolicy } from '@libs/PolicyUtils' ;
3838import type { SettingsNavigatorParamList } from '@navigation/types' ;
3939import NotFoundPage from '@pages/ErrorPage/NotFoundPage' ;
4040import AccessOrNotFoundWrapper from '@pages/workspace/AccessOrNotFoundWrapper' ;
@@ -155,17 +155,17 @@ function CategorySettingsPage({
155155 if ( ! policyCategory ) {
156156 return '' ;
157157 }
158- return formatRequiredFieldsTitle ( translate , policyCategory , policy ?. isAttendeeTrackingEnabled ) ;
159- } , [ policyCategory , translate , policy ?. isAttendeeTrackingEnabled ] ) ;
158+ return formatRequiredFieldsTitle ( translate , policyCategory , isAttendeeTrackingEnabled ( policy ) ) ;
159+ } , [ policyCategory , translate , policy ] ) ;
160160
161161 const requireFieldsPendingAction = useMemo ( ( ) => {
162- if ( policy ?. isAttendeeTrackingEnabled ) {
162+ if ( isAttendeeTrackingEnabled ( policy ) ) {
163163 // Pending fields are objects so we can't use nullish coalescing
164164 // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
165165 return policyCategory ?. pendingFields ?. areAttendeesRequired || policyCategory ?. pendingFields ?. areCommentsRequired ;
166166 }
167167 return policyCategory ?. pendingFields ?. areCommentsRequired ;
168- } , [ policyCategory ?. pendingFields , policy ?. isAttendeeTrackingEnabled ] ) ;
168+ } , [ policyCategory ?. pendingFields , policy ] ) ;
169169
170170 // eslint-disable-next-line rulesdir/no-negated-variables
171171 const showCannotDeleteOrDisableLastCategoryModal = useCallback ( ( ) => {
0 commit comments