Skip to content

Commit b3e236e

Browse files
committed
pick policyID
1 parent ddcb935 commit b3e236e

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/hooks/useLastAccessedReport.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import mapOnyxCollectionItems from '@src/utils/mapOnyxCollectionItems';
77
import useOnyx from './useOnyx';
88

99
// Optimized selectors based on complete field usage analysis in findLastAccessedReport
10-
type ReportSelector = Pick<Report, 'reportID' | 'lastReadTime' | 'chatType' | 'type' | 'participants' | 'invoiceReceiver' | 'ownerAccountID' | 'parentReportActionID'>;
10+
type ReportSelector = Pick<Report, 'reportID' | 'lastReadTime' | 'chatType' | 'type' | 'participants' | 'invoiceReceiver' | 'ownerAccountID' | 'parentReportActionID' | 'policyID'>;
1111

1212
type PolicySelector = Pick<Policy, 'id' | 'employeeList'>;
1313

@@ -25,6 +25,7 @@ const reportSelector = (report: OnyxEntry<Report>): ReportSelector =>
2525
invoiceReceiver: report.invoiceReceiver,
2626
ownerAccountID: report.ownerAccountID,
2727
parentReportActionID: report.parentReportActionID,
28+
policyID: report.policyID,
2829
}) as ReportSelector;
2930

3031
const policySelector = (policy: OnyxEntry<Policy>): PolicySelector =>

0 commit comments

Comments
 (0)