diff --git a/application/controllers/HostController.php b/application/controllers/HostController.php index 6b306b3..ac724cf 100644 --- a/application/controllers/HostController.php +++ b/application/controllers/HostController.php @@ -44,7 +44,7 @@ class HostController extends Controller $this->params->add('name', $hostName); - if ($host !== false) { + if ($host !== null) { $this->redirectNow(Url::fromPath('icingadb/host')->setParams($this->params)); } } else { diff --git a/application/controllers/ServiceController.php b/application/controllers/ServiceController.php index 29d40ce..2c0563d 100644 --- a/application/controllers/ServiceController.php +++ b/application/controllers/ServiceController.php @@ -49,7 +49,7 @@ class ServiceController extends Controller $this->params->add('name', $serviceName); $this->params->add('host.name', $hostName); - if ($service !== false) { + if ($service !== null) { $this->redirectNow(Url::fromPath('icingadb/service')->setParams($this->params)); } } else { diff --git a/library/Businessprocess/State/IcingaDbState.php b/library/Businessprocess/State/IcingaDbState.php index 1628ed7..68ac45d 100644 --- a/library/Businessprocess/State/IcingaDbState.php +++ b/library/Businessprocess/State/IcingaDbState.php @@ -63,8 +63,6 @@ class IcingaDbState } $queryHost = Host::on($this->backend)->with('state'); - IcingaDbObject::applyIcingaDbRestrictions($queryHost); - $queryHost->filter(Filter::equal('host.name', $hosts)); $hostObject = $queryHost->getModel()->getTableName(); @@ -78,8 +76,6 @@ class IcingaDbState $queryService->filter(Filter::equal('host.name', $hosts)); - IcingaDbObject::applyIcingaDbRestrictions($queryService); - Benchmark::measure('Retrieved states for ' . $queryService->count() . ' services in ' . $config->getName()); $configs = $config->listInvolvedConfigs();