Skip to content

Commit

Permalink
Allow users to see query string when query returns no data (apache#3585)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mogball authored and michellethomas committed May 23, 2018
1 parent 595e9cb commit 39ec83e
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,10 @@ export default class DisplayQueryButton extends React.PureComponent {
});
}
beforeOpen() {
if (['loading', null].indexOf(this.props.chartStatus) >= 0 || !this.props.queryResponse) {
if (
['loading', null].indexOf(this.props.chartStatus) >= 0
|| !this.props.queryResponse || !this.props.queryResponse.query
) {
this.fetchQuery();
} else {
this.setStateFromQueryResponse();
Expand Down

0 comments on commit 39ec83e

Please sign in to comment.