mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-27 07:44:05 +02:00
IcingaObject: fix resolveProperty in combination...
...with lazy-set properties
This commit is contained in:
parent
123b4c7549
commit
cb825b5b94
@ -610,6 +610,11 @@ abstract class IcingaObject extends DbObject implements IcingaConfigRenderer
|
|||||||
|
|
||||||
public function getResolvedProperty($key, $default = null)
|
public function getResolvedProperty($key, $default = null)
|
||||||
{
|
{
|
||||||
|
if (array_key_exists($key, $this->unresolvedRelatedProperties)) {
|
||||||
|
$this->resolveUnresolvedRelatedProperty($key);
|
||||||
|
$this->invalidateResolveCache();
|
||||||
|
}
|
||||||
|
|
||||||
$properties = $this->getResolvedProperties();
|
$properties = $this->getResolvedProperties();
|
||||||
if (property_exists($properties, $key)) {
|
if (property_exists($properties, $key)) {
|
||||||
return $properties->$key;
|
return $properties->$key;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user