QueryGroup: Fix infinite loop in edit mode (#67273)

pull/67283/head
Dominik Prokop 2 years ago committed by GitHub
parent d51e63520c
commit a62cb96089
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      public/app/features/query/components/QueryGroup.tsx

@ -99,7 +99,8 @@ export class QueryGroup extends PureComponent<Props, State> {
async componentDidUpdate() {
const { options } = this.props;
if (this.state.dataSource && options.dataSource.uid !== this.state.dataSource?.uid) {
const currentDS = await getDataSourceSrv().get(options.dataSource);
if (this.state.dataSource && currentDS.uid !== this.state.dataSource?.uid) {
this.setNewQueriesAndDatasource(options);
}
}

Loading…
Cancel
Save