Apply fixes from StyleCI (#12343)

This commit is contained in:
Jellyfrog
2020-11-23 19:56:23 +01:00
committed by GitHub
parent 2b59ff5fda
commit b022a30a5b
2 changed files with 2 additions and 3 deletions

View File

@@ -70,6 +70,7 @@ class DistributedPoller extends BaseValidation
if (PollerCluster::isActive()->exists()) {
$validator->info('Detected Dispatcher Service');
$this->checkDispatcherService($validator);
return;
}
@@ -98,13 +99,13 @@ class DistributedPoller extends BaseValidation
$node = PollerCluster::firstWhere('node_id', config('librenms.node_id'));
if (! $node->exists) {
$validator->fail('Dispatcher service is enabled on your cluster, but not in use on this node');
return;
}
if ($node->last_report->lessThan(Carbon::now()->subSeconds($node->getSettingValue('poller_frequency')))) {
$validator->fail('Dispatcher service has not reported stats within the last poller window');
}
}
private function checkPythonWrapper(Validator $validator)