mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
panels: fix loading panels with non-array targets (refactor)
This commit is contained in:
parent
e3b3b35dca
commit
fe798239b2
@ -125,9 +125,8 @@ export class PanelModel {
|
||||
}
|
||||
|
||||
ensureQueryIds() {
|
||||
if (this.targets) {
|
||||
for (let i = 0; i < this.targets.length; i++) {
|
||||
const query = this.targets[i];
|
||||
if (this.targets && _.isArray(this.targets)) {
|
||||
for (const query of this.targets) {
|
||||
if (!query.refId) {
|
||||
query.refId = this.getNextQueryLetter();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user