-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix invite page not loading after creating new workspace #5729
Conversation
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice catch
@@ -107,7 +107,7 @@ class WorkspaceInvitePage extends React.Component { | |||
* @returns {Boolean} | |||
*/ | |||
getShouldShowAlertPrompt() { | |||
return _.size(lodashGet(this.props.policy, 'errors', {})) > 0 || this.props.policy.alertMessage.length > 0; | |||
return _.size(lodashGet(this.props.policy, 'errors', {})) > 0 || lodashGet(this.props.policy, 'alertMessage.length') > 0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return _.size(lodashGet(this.props.policy, 'errors', {})) > 0 || lodashGet(this.props.policy, 'alertMessage.length') > 0; | |
return _.size(lodashGet(this.props.policy, 'errors', {})) > 0 || lodashGet(this.props.policy, 'alertMessage', '').length > 0; |
NAB, maybe slightly more correct?
Otherwise we are doing undefined > 0
which does eval to false
but seems weird.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, yea this is better.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Made a 2-min PR to implement this real quick.
#5738
Fix invite page not loading after creating new workspace (cherry picked from commit 13ac792)
🚀 Cherry-picked to staging by @Luke9389 in version: 1.1.7-1 🚀
@Expensify/applauseleads please QA this PR and check it off on the deploy checklist if it passes. |
🚀 Deployed to production by @AndrewGable in version: 1.1.7-24 🚀
|
🚀 Deployed to production by @roryabraham in version: 1.1.8-9 🚀
|
@Luke9389, please review when you get the chance
CC: @marcaaron
Details
Fixes a TypeError that causes a blank page from the invite modal. This happens after creating a new workspace and then
Fixed Issues
$ #5727
Tests
Same as Web QA done locally
QA Steps
Tested On
Screenshots
Web