Skip to content
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

Onboarding spreadsheet bugs #38 (GH-2259), #44 (GH-2306), and #45 (GH-2305) #675

Merged
merged 16 commits into from Mar 17, 2021
Merged
Changes from 1 commit
Commits
File filter
Filter file types
Jump to
Jump to file
Failed to load files.

Always

Just for now

Move setting of default plan in plan select view to componentDidMount…

… to avoid using setTimeout to setState in constructor
  • Loading branch information
wlycdgr committed Mar 15, 2021
commit c00e26f07bc580f53106662f5b3754fc78e111b5
@@ -89,11 +89,12 @@ class ChoosePlanView extends React.Component {
this.state = {
selectedPlan: '',
expanded: false,
readyToRender: false, // setTimeout does not block
readyToRender: false, // after the component mounts, we need to setDefaultPlan()
};
// TODO can we do this in a way that guarantees user object will be available when we need it?
// TODO we prob need to updated AccountReducer so we have a way to distinguish between 'no user' and 'user not fetched yet'
setTimeout(this.setDefaultPlan, 200);
}

componentDidMount() {
this.setDefaultPlan();
}

isBasicUser = () => {
ProTip! Use n and p to navigate between commits in a pull request.