Fix bug with deleting all code

This commit is contained in:
emizzle 2018-08-28 00:22:14 +10:00
parent d7f1749d3a
commit 76f8c53c5d

View File

@ -29,7 +29,7 @@ class FiddleContainer extends Component {
}
componentDidUpdate(prevProps){
if(prevProps.lastFiddle !== this.props.lastFiddle){
if(this.props.lastFiddle && (prevProps.lastFiddle !== this.props.lastFiddle)){
this._onCodeChange(this.props.lastFiddle);
}
}