Remove redundant getAuthToken() calls from action files since network layer adds authToken automatically#79114
Conversation
… layer adds authToken automatically
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
PR doesn’t need product input as a refactor PR. Unassigning and unsubscribing myself. |
|
@abbasifaizan70 I don't think it should be fully No QA, but I also don't think they need to test out every single API. Could you pick out maybe 2-3 API calls to have QA verify? |
@tgolen its wokring fine. |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / Safari79114_web_chrome.mov |
brunovjk
left a comment
There was a problem hiding this comment.
LGTM.
Could you pick out maybe 2-3 API calls to have QA verify?
@abbasifaizan70 Could you add some tests for the QA team? Thank you.
|
We did not find an internal engineer to review this PR, trying to assign a random engineer to #78797 as well as to this PR... Please reach out for help on Slack if no one gets assigned! |
|
Ready for you @tgolen ^ |
Oops, I merged without these being updated. I assume you'll add those soon though since I saw your 👍 reaction |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
@tgolen I already added. Thanks |
|
🚀 Deployed to staging by https://github.com/tgolen in version: 9.3.1-0 🚀
|
|
🚀 Deployed to production by https://github.com/francoisl in version: 9.3.1-1 🚀
|


This PR will remove redundant getAuthToken() calls from below files.
addNewCompanyCardsFeed - Remove authToken fetch and guard clause
setWorkspaceCompanyCardFeedName - Remove authToken fetch
setWorkspaceCompanyCardTransactionLiability - Remove authToken fetch
deleteWorkspaceCompanyCardFeed - Remove authToken fetch
unassignWorkspaceCompanyCard - Remove authToken fetch
updateWorkspaceCompanyCard - Remove authToken fetch
updateCompanyCardName - Remove authToken fetch
updateCardTransactionStartDate - Remove authToken fetch
setCompanyCardExportAccount - Remove authToken fetch
openPolicyCompanyCardsPage - Remove authToken fetch
setFeedStatementPeriodEndDay - Remove authToken fetch
Explanation of Change
Fixed Issues
$ #78797
PROPOSAL: #78797 (comment)
Tests
No test cases it was only the removal of redundant code.
Open Workspace Company Cards Page (from CompanyCards.ts)
Go to any workspace → Company Cards section
Verify the page loads and shows cards correctly
Open Workspace Expensify Cards Page (from Policy/Policy.ts)
Go to any workspace → Expensify Cards section
Verify the page loads successfully
Offline tests
No test cases it was only the removal of redundant code.
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
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