mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Resolved bug where $text would use the previous iteration if $sla_type was unknown.
Now set a default $text value which will be over written if $sla_type is known.
This commit is contained in:
@ -9,6 +9,9 @@ $slas = dbFetchRows('SELECT * FROM `slas` WHERE `device_id` = ? AND `deleted` =
|
||||
// Collect types
|
||||
$sla_types = array('all' => 'All');
|
||||
foreach ($slas as $sla) {
|
||||
// Set a default type, if we know about it, it will be overwritten below.
|
||||
$text = 'Unknown';
|
||||
|
||||
$sla_type = $sla['rtt_type'];
|
||||
|
||||
if (!in_array($sla_type, $sla_types)) {
|
||||
|
Reference in New Issue
Block a user