Commit 6f4f3278 by kay delaney Committed by GitHub

Datasource/Loki: Empty metric name no longer replaced by query (#20924)

Closes #20762
parent 30771f25
......@@ -284,7 +284,7 @@ function createMetricLabel(labelData: { [key: string]: string }, options?: Trans
? getOriginalMetricName(labelData)
: renderTemplate(templateSrv.replace(options.legendFormat), labelData);
if (!label || label === '{}') {
if (!label) {
label = options.query;
}
return label;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment