IcingaArguments: play nice with DSL in set_if
Recent changes to ITL ships with such an example.
This commit is contained in:
parent
c6c8b75c74
commit
9786fd5dae
|
@ -135,6 +135,12 @@ class IcingaArguments implements Iterator, Countable, IcingaConfigRenderer
|
|||
}
|
||||
}
|
||||
|
||||
if (array_key_exists('set_if', $attrs) && is_object($attrs['set_if'])) {
|
||||
if ($attrs['set_if']->type === 'Function') {
|
||||
$attrs['set_if'] = '/* Unable to fetch function body through API */';
|
||||
$attrs['set_if_format'] = 'expression';
|
||||
}
|
||||
}
|
||||
|
||||
$this->add(IcingaCommandArgument::create($attrs));
|
||||
|
||||
|
|
Loading…
Reference in New Issue