@@ -2,7 +2,7 @@ import {hasPaymentMethodError} from '@libs/actions/PaymentMethods';
22import { hasPartiallySetupBankAccount , hasPersonalBankAccountMissingInfo } from '@libs/BankAccountUtils' ;
33import { hasPendingExpensifyCardAction } from '@libs/CardUtils' ;
44import { hasSubscriptionGreenDotInfo , hasSubscriptionRedDotError } from '@libs/SubscriptionUtils' ;
5- import { hasLoginListError , hasLoginListInfo } from '@libs/UserUtils' ;
5+ import { hasDeviceManagementError , hasLoginListError , hasLoginListInfo } from '@libs/UserUtils' ;
66import CONST from '@src/CONST' ;
77import ONYXKEYS from '@src/ONYXKEYS' ;
88import type IndicatorStatus from '@src/types/utils/IndicatorStatus' ;
@@ -33,6 +33,7 @@ function useAccountIndicatorChecks(): AccountIndicatorChecksResult {
3333 const [ session ] = useOnyx ( ONYXKEYS . SESSION ) ;
3434 const [ reimbursementAccount ] = useOnyx ( ONYXKEYS . REIMBURSEMENT_ACCOUNT ) ;
3535 const [ policies ] = useOnyx ( ONYXKEYS . COLLECTION . POLICY ) ;
36+ const [ hasDeviceManagementErrorValue ] = useOnyx ( ONYXKEYS . LOGINS , { selector : hasDeviceManagementError } ) ;
3637
3738 const {
3839 companyCards : { shouldShowRBR : hasCompanyCardFeedErrors } ,
@@ -59,6 +60,7 @@ function useAccountIndicatorChecks(): AccountIndicatorChecksResult {
5960 [ CONST . INDICATOR_STATUS . HAS_PHONE_NUMBER_ERROR ] : ! ! privatePersonalDetails ?. errorFields ?. phoneNumber ,
6061 [ CONST . INDICATOR_STATUS . HAS_EMPLOYEE_CARD_FEED_ERRORS ] : ! isPolicyAdmin ? hasCompanyCardFeedErrors : false ,
6162 [ CONST . INDICATOR_STATUS . HAS_LOCKED_BANK_ACCOUNT ] : Object . values ( bankAccountList ?? { } ) . some ( ( bankAccount ) => bankAccount ?. accountData ?. state === CONST . BANK_ACCOUNT . STATE . LOCKED ) ,
63+ [ CONST . INDICATOR_STATUS . HAS_DEVICE_MANAGEMENT_ERROR ] : hasDeviceManagementErrorValue ,
6264 } ;
6365
6466 const infoChecks : Partial < Record < IndicatorStatus , boolean > > = {
0 commit comments