This commit is contained in:
Cassie Tarakajian 2016-10-25 17:05:53 -04:00
parent 315e83c593
commit 17fab1782e

View file

@ -155,9 +155,7 @@ class IDEView extends React.Component {
} }
warnIfUnsavedChanges() { // eslint-disable-line warnIfUnsavedChanges() { // eslint-disable-line
if (this.props.ide.unsavedChanges if (this.props.ide.unsavedChanges) {
&& ((this.props.project.owner && this.props.project.owner.id === this.props.user.id)
|| (!this.props.project.owner))) {
if (!window.confirm('Are you sure you want to leave this page? You have unsaved changes.')) { if (!window.confirm('Are you sure you want to leave this page? You have unsaved changes.')) {
return false; return false;
} }