mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Fix map bug caused by loopback cable
Fix a map bug where vis.js aborts because a device is inserted twice. Need to add to $tmp_ids before checking the next device.
This commit is contained in:
@@ -132,10 +132,10 @@ foreach ($list as $items) {
|
||||
if (!in_array($items['local_device_id'],$tmp_ids)) {
|
||||
$tmp_devices[] = array('id'=>$items['local_device_id'],'label'=>$items['local_hostname'],'title'=>generate_device_link($local_device,'',array(),'','','',0),'shape'=>'box');
|
||||
}
|
||||
array_push($tmp_ids,$items['local_device_id']);
|
||||
if (!in_array($items['remote_device_id'],$tmp_ids)) {
|
||||
$tmp_devices[] = array('id'=>$items['remote_device_id'],'label'=>$items['remote_hostname'],'title'=>generate_device_link($remote_device,'',array(),'','','',0),'shape'=>'box');
|
||||
}
|
||||
array_push($tmp_ids,$items['local_device_id']);
|
||||
array_push($tmp_ids,$items['remote_device_id']);
|
||||
$speed = $items['local_ifspeed']/1000/1000;
|
||||
if ($speed == 100) {
|
||||
|
Reference in New Issue
Block a user