@@ -31,7 +31,6 @@ import useThemeStyles from '@hooks/useThemeStyles';
3131import useThreeDotsAnchorPosition from '@hooks/useThreeDotsAnchorPosition' ;
3232import { isAuthenticationError , isConnectionInProgress , isConnectionUnverified , removePolicyConnection , syncConnection } from '@libs/actions/connections' ;
3333import { shouldShowQBOReimbursableExportDestinationAccountError } from '@libs/actions/connections/QuickbooksOnline' ;
34- import { getAssignedSupportData } from '@libs/actions/Policy/Policy' ;
3534import { isExpensifyCardFullySetUp } from '@libs/CardUtils' ;
3635import {
3736 areSettingsInErrorFields ,
@@ -179,13 +178,6 @@ function PolicyAccountingPage({policy}: PolicyAccountingPageProps) {
179178 setDateTimeToRelative ( '' ) ;
180179 } , [ getDatetimeToRelative , successfulDate ] ) ;
181180
182- useEffect ( ( ) => {
183- if ( ! policyID ) {
184- return ;
185- }
186- getAssignedSupportData ( policyID ) ;
187- } , [ policyID ] ) ;
188-
189181 const calculateAndSetThreeDotsMenuPosition = useCallback ( ( ) => {
190182 if ( shouldUseNarrowLayout ) {
191183 return Promise . resolve ( { horizontal : 0 , vertical : 0 } ) ;
@@ -512,8 +504,8 @@ function PolicyAccountingPage({policy}: PolicyAccountingPageProps) {
512504
513505 const [ chatTextLink , chatReportID ] = useMemo ( ( ) => {
514506 // If they have an onboarding specialist assigned display the following and link to the #admins room with the setup specialist.
515- if ( account ?. adminsRoomReportID ) {
516- return [ translate ( 'workspace.accounting.talkYourOnboardingSpecialist' ) , account ?. adminsRoomReportID ] ;
507+ if ( policy ?. chatReportIDAdmins ) {
508+ return [ translate ( 'workspace.accounting.talkYourOnboardingSpecialist' ) , policy ?. chatReportIDAdmins ] ;
517509 }
518510
519511 // If not, if they have an account manager assigned display the following and link to the DM with their account manager.
@@ -626,7 +618,7 @@ function PolicyAccountingPage({policy}: PolicyAccountingPageProps) {
626618 />
627619 < View style = { [ ! isLargeScreenWidth ? styles . flexColumn : styles . flexRow ] } >
628620 < Text style = { styles . textSupporting } > { translate ( 'workspace.accounting.needAnotherAccounting' ) } </ Text >
629- < TextLink onPress = { ( ) => Navigation . navigate ( ROUTES . REPORT_WITH_ID . getRoute ( chatReportID ) ) } > { chatTextLink } </ TextLink >
621+ < TextLink onPress = { ( ) => Navigation . navigate ( ROUTES . REPORT_WITH_ID . getRoute ( String ( chatReportID ) ) ) } > { chatTextLink } </ TextLink >
630622 </ View >
631623 </ View >
632624 ) }
0 commit comments