Skip to content

Commit

Permalink
Merge pull request #33981 from paultsimura/fix/32658-lazy-lhn-subtext
Browse files Browse the repository at this point in the history
fix: use lazy loading for the IOU Report previews
  • Loading branch information
yuwenmemon authored Jan 16, 2024
2 parents 93e68b5 + 9cbd2c6 commit a7a3e7f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/libs/OptionsListUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -436,10 +436,9 @@ function getLastMessageTextForReport(report) {
lastMessageTextFromReport = lodashGet(lastReportAction, 'message[0].text', '');
} else if (ReportActionUtils.isCreatedTaskReportAction(lastReportAction)) {
lastMessageTextFromReport = TaskUtils.getTaskCreatedMessage(lastReportAction);
} else {
lastMessageTextFromReport = report ? report.lastMessageText || '' : '';
}
return lastMessageTextFromReport;

return lastMessageTextFromReport || lodashGet(report, 'lastMessageText', '');
}

/**
Expand Down

0 comments on commit a7a3e7f

Please sign in to comment.