mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-09-25 18:59:05 +02:00
Convert $imports keys to string explicitly
The keys of $imports in IcingaObjectImports must be converted to string explicitly or else it establishes incorrect parent-child relation in icinga_host_inheritance table in case the key is integer value and there is an host object with id = key(integer) icinga_host table. This results in undefined offset while triggering sync rule.
This commit is contained in:
parent
6289bf065f
commit
90b5f6fdac
@ -232,6 +232,7 @@ class IcingaObjectImports implements Iterator, Countable, IcingaConfigRenderer
|
||||
{
|
||||
$list = [];
|
||||
foreach ($this->listImportNames() as $name) {
|
||||
$name = (string) $name;
|
||||
$list[$name] = $this->getObject($name);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user