This commit is contained in:
Cassie Tarakajian 2017-01-08 16:42:20 -05:00
parent dee9688ece
commit 885967d8e3
2 changed files with 4 additions and 1 deletions

View File

@ -9,7 +9,9 @@ function Nav(props) {
<a
className="nav__new"
onClick={() => {
if (props.warnIfUnsavedChanges()) {
if (!props.unsavedChanges) {
props.newProject();
} else if (props.warnIfUnsavedChanges()) {
props.newProject();
}
}}

View File

@ -210,6 +210,7 @@ class IDEView extends React.Component {
stopSketch={this.props.stopSketch}
showShareModal={this.props.showShareModal}
openForceAuthentication={this.props.openForceAuthentication}
unsavedChanges={this.props.ide.unsavedChanges}
warnIfUnsavedChanges={this.warnIfUnsavedChanges}
/>
<Toolbar