Commit 057696a0 by Torkel Ödegaard Committed by GitHub

Merge pull request #14002 from Nexucis/bugfix/template-srv

[Bugfix] Don't drop the value when it's equal to None
parents 733f2b06 2abf8a0e
......@@ -28,7 +28,7 @@ export class TemplateSrv {
const existsOrEmpty = value => value || value === '';
this.index = this.variables.reduce((acc, currentValue) => {
if (currentValue.current && !currentValue.current.isNone && existsOrEmpty(currentValue.current.value)) {
if (currentValue.current && (currentValue.current.isNone || existsOrEmpty(currentValue.current.value))) {
acc[currentValue.name] = currentValue;
}
return acc;
......
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