diff --git a/packages/embark-ui/src/containers/EditorContainer.js b/packages/embark-ui/src/containers/EditorContainer.js index 30a946d1f..603eb61b7 100644 --- a/packages/embark-ui/src/containers/EditorContainer.js +++ b/packages/embark-ui/src/containers/EditorContainer.js @@ -81,7 +81,7 @@ class EditorContainer extends React.Component { if(this.props.contracts.length && this.props.transaction) { const debuggingContract = this.props.contracts.find(contract => contract.address === this.props.transaction.to) - if (this.state.debuggingContract !== debuggingContract) { + if (debuggingContract && this.state.debuggingContract !== debuggingContract) { const editorWidth = this.getNewEditorWidth(OPERATIONS.LESS) this.setState({currentAsideTab: TextEditorToolbarTabs.Debugger, editorWidth, debuggingContract}) this.props.fetchFile({path: debuggingContract.path});