Only include reportCreationData if nonempty to prevent WAF violation - #21593
Conversation
|
@sobitneupane 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] |
|
@mananjadhav 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] |
Beamanator
left a comment
There was a problem hiding this comment.
Looks good! Juuust wondering, was there a WAF error if we sent reportCreationData as undefined or null?
Also coulddd we have just defaulted to an empty object string here?
reportCreationData: !_.isEmpty(membersChats.reportCreationData) ? JSON.stringify(membersChats.reportCreationData) : '{}',
I think reportCreationData should always be at least an object per this line. I think for some reason PHP is interpreting an empty object string |
neil-marcellini
left a comment
There was a problem hiding this comment.
Nice looks good.
|
✋ 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 https://github.com/Li357 in version: 1.3.34-0 🚀
|
|
🚀 Deployed to production by https://github.com/thienlnam in version: 1.3.34-1 🚀
|
Fixed Issues
$ https://github.com/Expensify/Expensify/issues/294380
Tests
reportCreationDatais not passed in the API requestOffline tests
N/A
QA Steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)myBool && <MyComponent />.src/languages/*files and using the translation methodWaiting for Copylabel for a copy review on the original GH to get the correct copy.STYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)/** comment above it */thisproperly 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)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
Web
Mobile Web - Chrome
Mobile Web - Safari
Desktop
iOS
Android