[No QA] deprecate session data & refactor getCleanUpTransactionThreadReportOnyxData#86605
[No QA] deprecate session data & refactor getCleanUpTransactionThreadReportOnyxData#86605tgolen merged 8 commits intoExpensify:mainfrom
getCleanUpTransactionThreadReportOnyxData#86605Conversation
|
@ikevin127 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] |
getCleanUpTransactionThreadReportOnyxData
| const allTransactionViolations = getAllTransactionViolations(); | ||
| const allReports = getAllReports(); | ||
| const currentUserEmail = getCurrentUserEmail(); | ||
| const currentUserAccountID = getUserAccountID(); |
Reviewer Checklist
Screenshots/VideosScreen.Recording.2026-03-28.at.15.56.14.mov |
| ...chatReport, | ||
| lastReadTime: DateUtils.getDBTime(), | ||
| hasOutstandingChildRequest: hasOutstandingChildRequest(chatReport, iouReport?.reportID, currentUserEmail, currentUserAccountIDParam, allTransactionViolations, undefined), | ||
| hasOutstandingChildRequest: hasOutstandingChildRequest(chatReport, iouReport?.reportID, deprecatedCurrentUserEmail, currentUserAccountIDParam, allTransactionViolations, undefined), |
There was a problem hiding this comment.
Naming Consistency: Consider standardizing on currentUserAccountID across all call sites (currently uses currentUserAccountIDParam in some places, which is existing codebase convention).
There was a problem hiding this comment.
Not in the scope of this project. Will update later.
There was a problem hiding this comment.
Yeah, I agree with the suggestion too. I'm fine if you update it in later PRs.
ikevin127
left a comment
There was a problem hiding this comment.
📊 OVERALL ASSESSMENT
| Category | Status |
|---|---|
| Code Quality | ✅ EXCELLENT - Proper deprecation, clear naming |
| Onyx Patterns | ✅ CORRECT - Moves away from anti-pattern |
| Type Safety | ✅ GOOD - Proper types enforced |
| Error Handling | ✅ ADEQUATE - Proper null checks |
✅ Approved - This PR follows Expensify's architectural patterns correctly and is safe to merge after verification that test coverage exists for all modified call sites.
Manual tests I've ran: 3 Online/Offline Tests
- Online: Create and delete expense with transaction thread - verify thread cleanup works correctly ✅
- Offline: Delete expense while offline, then go online - verify optimistic data syncs correctly ✅
- Merge Duplicates: Merge duplicate expenses - verify source transaction thread cleanup works ✅
|
No product review needed |
|
cc: @tgolen |
| ...chatReport, | ||
| lastReadTime: DateUtils.getDBTime(), | ||
| hasOutstandingChildRequest: hasOutstandingChildRequest(chatReport, iouReport?.reportID, currentUserEmail, currentUserAccountIDParam, allTransactionViolations, undefined), | ||
| hasOutstandingChildRequest: hasOutstandingChildRequest(chatReport, iouReport?.reportID, deprecatedCurrentUserEmail, currentUserAccountIDParam, allTransactionViolations, undefined), |
There was a problem hiding this comment.
Yeah, I agree with the suggestion too. I'm fine if you update it in later PRs.
|
Quite a few tests are failing, so I can't merge it yet. |
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
Ready @tgolen |
|
🚧 @tgolen 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/tgolen in version: 9.3.52-0 🚀
Bundle Size Analysis (Sentry): |
|
No help site changes are required for this PR. This is a purely internal refactoring that renames module-level variables ( |
Explanation of Change
Fixed Issues
$ #66519
PROPOSAL:
Tests
Offline tests
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, 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.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari