fix bug showing no nodes when only one matches in netmap
This commit is contained in:
@@ -219,8 +219,9 @@ ajax '/ajax/data/device/netmap' => require_login sub {
|
|||||||
|
|
||||||
DEVICE: while (my $device = $devices->next) {
|
DEVICE: while (my $device = $devices->next) {
|
||||||
# if in neighbors or vlan mode then use %ok_dev to filter
|
# if in neighbors or vlan mode then use %ok_dev to filter
|
||||||
next DEVICE if (($mapshow eq 'neighbors') or $vlan)
|
next DEVICE if ($device->ip ne $qdev->ip)
|
||||||
and (not $ok_dev{$device->ip});
|
and (($mapshow eq 'neighbors') or $vlan)
|
||||||
|
and (not $ok_dev{$device->ip}); # showing only neighbors but no link
|
||||||
|
|
||||||
# if location picked then filter
|
# if location picked then filter
|
||||||
next DEVICE if ((scalar @lgrplist) and ((!defined $device->location)
|
next DEVICE if ((scalar @lgrplist) and ((!defined $device->location)
|
||||||
|
|||||||
Reference in New Issue
Block a user