mirror of
https://github.com/stylersnico/librenms.git
synced 2026-07-12 16:06:25 +02:00
Added fallback for poller_group if empty
This commit is contained in:
@@ -526,8 +526,12 @@ function utime()
|
||||
|
||||
function createHost($host, $community = NULL, $snmpver, $port = 161, $transport = 'udp', $v3 = array(), $poller_group='0')
|
||||
{
|
||||
global $config;
|
||||
$host = trim(strtolower($host));
|
||||
|
||||
if (is_numeric($poller_group) === FALSE) {
|
||||
$poller_group = $config['distributed_poller_group'];
|
||||
}
|
||||
$device = array('hostname' => $host,
|
||||
'sysName' => $host,
|
||||
'community' => $community,
|
||||
|
||||
Reference in New Issue
Block a user