[Phase 2] Part 4 - Migrate deprecatedGetReportName to getReportName in libs - #98047
marcochavezf merged 17 commits into
Conversation
bd40d75 to
b4c232b
Compare
e585dc3 to
122f961
Compare
Codecov Report❌ Looks like you've decreased code coverage for some files. Please write tests to increase, or at least maintain, the existing level of code coverage. See our documentation here for how to interpret this table.
|
…e remaining callers A2: narrow getChatListItemReportName and getReportPreviewMessageForCopy to take a derivedReportName string; SearchActionHeader now sources it via useDerivedReportNameByReportID. Notifications: thread a derivedReportName string through showReportActionNotification, the LocalNotification chain and ModifiedExpenseMessage instead of the whole reportAttributes Record. Task: narrow getShareDestination; DynamicNewTaskPage sources the name via useDerivedReportNameByReportID. Sweep: replace the remaining deprecatedGetReportName call sites in OptionsListUtils, SidebarUtils, SearchQueryUtils and SearchUIUtils with getReportName, extracting the single report name inline (no behavior change). Part of Expensify#66427 Phase 2. Stacked on the transaction-message narrowing PR.
- Remove deprecated wrapper function and its export - All callers already migrated to getReportName directly
122f961 to
9091962
Compare
|
@DylanDylann Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 90919627d5
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
JmillsExpensify
left a comment
There was a problem hiding this comment.
No product review required.
- Add derivedMovedFromReportName param to showReportActionNotification - Look up report name by moved-from report ID instead of current report ID - Fixes notification showing destination name instead of origin name - Update tests to match new parameter signature
5c32170 to
572ceff
Compare
…ReportName Extract reportName from reportAttributesDerived using lastActionReport.reportID instead of passing the whole object. Remove unnecessary eslint-disable comment.
…eportName More specific name for the moved-from report name passed through the modified expense notification flow.
- Remove unused ReportAttributesDerivedValue import - Reorder params so default param is last - Replace ID default empty string with type assertion
…reportName - Change reportName param from optional to string | undefined in getShareDestination - Update test calls to pass explicit undefined for trailing argument
…nature changes - Add explicit reportName: undefined to ModifiedExpenseMessage test fixtures - Pass convertToDisplayString arg to getChatListItemReportName calls in ReportUtilsTest
- Add missing reportName property to getForReportAction call - Fix indentation to satisfy oxfmt check
Reviewer Checklist
Screenshots/VideosScreen.Recording.2026-09-11.at.16.08.20.mov |
| currentUserAccountID: number | undefined; | ||
| currentUserLogin: string; | ||
| reportAttributes?: ReportAttributesDerivedValue['reports']; | ||
| reportName: string | undefined; |
There was a problem hiding this comment.
rename getForReportAction({reportName}) → movedFromReportName
|
@hoangzinh One NIT |
getShareDestination now requires a reportName parameter. Pass undefined for the 3 test call sites to fix typecheck.
Clarify intent of the parameter in getForReportAction — it is only used for the "moved from" report message, not as a general report name.
aa3898a to
9fc0fb0
Compare
|
@DylanDylann this PR is ready for next review round |
|
🚧 marcochavezf has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/marcochavezf in version: 9.4.82-0 🚀
|
|
No help site changes are required for this PR, so I did not create a draft docs PR. This is an internal refactor: it removes the Why no docs updateHelp site articles in
|
|
🚀 Deployed to staging by https://github.com/marcochavezf in version: 9.4.86-0 🚀
|
|
🤖 No help site changes required — no draft PR created. This PR is a mechanical internal refactor. It deletes the Why nothing in
|
|
🚀 Deployed to staging by https://github.com/marcochavezf in version: 9.4.89-0 🚀
|
|
🚀 Deployed to production by https://github.com/luacmartins in version: 9.4.89-0 🚀
Bundle Size Analysis (Sentry): |
Explanation of Change
Fixed Issues
$ #66427
PROPOSAL:
Tests
Offline tests
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
1. Report name displays correctly in LHN
2. Browser Notification (Web only)
3. Search displays correct report name
4. Task — Share Destination
5. Invoice Room
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectionAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Screen.Recording.2026-08-10.211333.mp4