Protect from potentially undefined function call#8626
Conversation
|
LGTM if I had to guess I'd say we are calling App/src/libs/NetworkConnection.js Lines 98 to 99 in c237f36 then either a request times out which triggers the recheck App/src/libs/Network/NetworkEvents.js Lines 17 to 21 in c237f36 OR we got a "Failed to fetch" error after we logged out somehow and forced a "recheck" via this code Line 131 in 27ddbdd |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by @marcaaron in version: 1.1.56-0 🚀
|
|
🚀 Deployed to production by @francoisl in version: 1.1.56-0 🚀
|
CC @marcaaron
Details
Simply add a protective condition to a NetworkConnection function that may be causing this mobile Exception.
Fixed Issues
$ https://github.com/Expensify/Expensify/issues/206552
Tests
PR Review Checklist
Contributor (PR Author) Checklist
### Fixed Issuessection aboveTestssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*filesSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)/** comment above it */displayNamepropertythisproperly so there are no scoping issues (i.e. foronClick={this.submit}the methodthis.submitshould be bound tothisin the constructor)thisare necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);ifthis.submitis never passed to a component event handler likeonClick)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)Avataris modified, I verified thatAvataris working as expected in all cases)PR Reviewer Checklist
### Fixed Issuessection aboveTestssectionQA stepssectiontoggleReportand notonIconClick).src/languages/*filesSTYLE.md) were followed/** comment above it */displayNamepropertythisproperly so there are no scoping issues (i.e. foronClick={this.submit}the methodthis.submitshould be bound tothisin the constructor)thisare necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);ifthis.submitis never passed to a component event handler likeonClick)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)Avataris modified, I verified thatAvataris working as expected in all cases)QA Steps
Screenshots
Web
Mobile Web
Desktop
N/A - please test Desktop while reviewing the PR!
iOS
Android