From 958b19758ca2a4d5b49a1041e66d97ab9acb3c4e Mon Sep 17 00:00:00 2001 From: Thomas Gelf Date: Fri, 15 Jan 2021 12:26:10 +0100 Subject: [PATCH] DataController: allow for IcingaHost in dictionary --- application/controllers/DataController.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/application/controllers/DataController.php b/application/controllers/DataController.php index 7ef1ed10..ae4bbcf3 100644 --- a/application/controllers/DataController.php +++ b/application/controllers/DataController.php @@ -9,6 +9,7 @@ use Icinga\Module\Director\Forms\DirectorDatalistForm; use Icinga\Module\Director\Forms\IcingaServiceDictionaryMemberForm; use Icinga\Module\Director\Objects\DirectorDatalist; use Icinga\Module\Director\Objects\IcingaHost; +use Icinga\Module\Director\Objects\IcingaObject; use Icinga\Module\Director\Objects\IcingaService; use Icinga\Module\Director\PlainObjectRenderer; use Icinga\Module\Director\Web\Controller\ActionController; @@ -287,11 +288,11 @@ class DataController extends ActionController } /** - * @param IcingaService $object + * @param IcingaObject $object * @param $varName * @return array */ - protected function getCurrentInstances(IcingaService $object, $varName) + protected function getCurrentInstances(IcingaObject $object, $varName) { $currentVars = $object->getVars(); if (isset($currentVars->$varName)) { @@ -338,11 +339,11 @@ class DataController extends ActionController } /** - * @param IcingaService $object + * @param IcingaObject $object * @param $varName * @return string */ - protected function prepareSubjectsLabel(IcingaService $object, $varName) + protected function prepareSubjectsLabel(IcingaObject $object, $varName) { if ($object instanceof IcingaService) { $hostName = $object->get('host');