Merge pull request #325 from rschamp/bugfix/project-clobbering

Stop clobbering loading projects with default data
This commit is contained in:
Ray Schamp authored and GitHub committed 2017-04-24 14:36:59 -04:00
commit c58727b24c
1 file changed
+2 -1
+2 -1
View File
@@ -19,7 +19,7 @@ class App extends React.Component {
this.updateProject = this.updateProject.bind(this);
this.state = {
projectId: null,
projectData: JSON.stringify(ProjectLoader.DEFAULT_PROJECT_DATA)
projectData: this.fetchProjectId().length ? null : ProjectLoader.DEFAULT_PROJECT_DATA
};
}
componentDidMount () {
@@ -49,6 +49,7 @@ class App extends React.Component {
}
}
render () {
if (this.state.projectData === null) return null;
return (
<GUI
basePath={this.props.basePath}