Handle health sensors with underscores in the name. (#10123)

This commit is contained in:
Martijn Schmidt
2019-04-27 17:10:31 +02:00
committed by PipoCanaja
parent b8c4f38fb5
commit af5377e06c

View File

@@ -803,7 +803,7 @@ function list_available_health_graphs()
$device_id = ctype_digit($hostname) ? $hostname : getidbyname($hostname); $device_id = ctype_digit($hostname) ? $hostname : getidbyname($hostname);
check_device_permission($device_id); check_device_permission($device_id);
if (isset($router['type'])) { if (isset($router['type'])) {
list($dump, $type) = explode('_', $router['type']); list($dump, $type) = explode('device_', $router['type']);
} }
$sensor_id = $router['sensor_id'] ?: null; $sensor_id = $router['sensor_id'] ?: null;
$graphs = array(); $graphs = array();