IcingaService: simplify command endpoint rendering
host.name doesn't work as of #11786. host_name should be fine for templates, objects and apply rules. I therefore also dropped the exception for service objects with use_agent and host_id.
This commit is contained in:
parent
5f1a21e1f0
commit
480e80709a
|
@ -173,11 +173,7 @@ class IcingaService extends IcingaObject
|
|||
return '';
|
||||
}
|
||||
|
||||
if ($this->hasBeenAssignedToHostTemplate() || $this->object_type !== 'object') {
|
||||
return c::renderKeyValue('command_endpoint', 'host.name');
|
||||
} else {
|
||||
return $this->renderRelationProperty('host', $this->host_id, 'command_endpoint');
|
||||
}
|
||||
return c::renderKeyValue('command_endpoint', 'host_name');
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue