@@ -22,7 +22,6 @@ import {combineOrderingOfReportsAndPersonalDetails, getSearchOptions} from '@lib
2222import Performance from '@libs/Performance' ;
2323import { getAllTaxRates , getCleanedTagName , shouldShowPolicy } from '@libs/PolicyUtils' ;
2424import type { OptionData } from '@libs/ReportUtils' ;
25- import { getReportOrDraftReport , isChatReport } from '@libs/ReportUtils' ;
2625import {
2726 getAutocompleteCategories ,
2827 getAutocompleteRecentCategories ,
@@ -126,16 +125,13 @@ function getItemHeight(item: OptionData | SearchQueryItem) {
126125
127126function SearchRouterItem ( props : UserListItemProps < OptionData > | SearchQueryListItemProps ) {
128127 const styles = useThemeStyles ( ) ;
129- const item = props . item ;
130- const report = getReportOrDraftReport ( item . reportID ) ;
131- const shouldDisplayRBR = report && isChatReport ( report ) && ! report . chatReportID ;
132128
133129 if ( isSearchQueryListItem ( props ) ) {
134130 return (
135131 < SearchQueryListItem
136132 // eslint-disable-next-line react/jsx-props-no-spreading
137133 { ...props }
138- shouldDisplayRBR = { shouldDisplayRBR }
134+ shouldDisplayRBR
139135 />
140136 ) ;
141137 }
@@ -144,7 +140,7 @@ function SearchRouterItem(props: UserListItemProps<OptionData> | SearchQueryList
144140 pressableStyle = { [ styles . br2 , styles . ph3 ] }
145141 // eslint-disable-next-line react/jsx-props-no-spreading
146142 { ...props }
147- shouldDisplayRBR = { shouldDisplayRBR }
143+ shouldDisplayRBR
148144 />
149145 ) ;
150146}
0 commit comments