[SQL Lab] Fix proptypes warning (#7691)

This commit is contained in:
Erik Ritter 2019-06-12 21:54:47 -07:00 committed by Grace Guo
parent 5cf06331fe
commit 2a453e1878
2 changed files with 2 additions and 2 deletions

View File

@ -37,7 +37,7 @@ const TAB_HEIGHT = 44;
*/
const propTypes = {
editorQueries: PropTypes.array.isRequired,
latestQueryId: PropTypes.string.isRequired,
latestQueryId: PropTypes.string,
dataPreviewQueries: PropTypes.array.isRequired,
actions: PropTypes.object.isRequired,
activeSouthPaneTab: PropTypes.string,

View File

@ -308,7 +308,7 @@ class SqlEditor extends React.PureComponent {
</div>
<SouthPane
editorQueries={this.props.editorQueries}
latestQueryId={this.props.latestQuery ? this.props.latestQuery.id : 0}
latestQueryId={this.props.latestQuery && this.props.latestQuery.id}
dataPreviewQueries={this.props.dataPreviewQueries}
actions={this.props.actions}
height={southPaneHeight}