diff --git a/src/components/Search/index.tsx b/src/components/Search/index.tsx index c8ecd2a4b1fb..0b1a6b9af512 100644 --- a/src/components/Search/index.tsx +++ b/src/components/Search/index.tsx @@ -674,8 +674,12 @@ function Search({ // If we're trying to open a transaction without a transaction thread, let's create the thread and navigate the user if (isTransactionItem && item.transactionThreadReportID === CONST.REPORT.UNREPORTED_REPORT_ID) { - createAndOpenSearchTransactionThread(item, hash, backTo); - return; + // If the report is unreported (self DM), we want to open the track expense thread instead of a report with an ID of 0 + const shouldOpenTransactionThread = !item.isFromOneTransactionReport || item.reportID === CONST.REPORT.UNREPORTED_REPORT_ID; + createAndOpenSearchTransactionThread(item, hash, backTo, undefined, shouldOpenTransactionThread); + if (shouldOpenTransactionThread) { + return; + } } if (isTransactionMemberGroupListItemType(item)) {