mirror of
https://github.com/stylersnico/librenms.git
synced 2026-07-12 16:06:25 +02:00
Updated vlans returned, was a double array by accident
This commit is contained in:
@@ -469,7 +469,7 @@ function get_vlans() {
|
|||||||
if ($device) {
|
if ($device) {
|
||||||
$vlans = dbFetchRows("SELECT vlan_vlan,vlan_domain,vlan_name,vlan_type,vlan_mtu FROM vlans WHERE `device_id` = ?", array($device_id));
|
$vlans = dbFetchRows("SELECT vlan_vlan,vlan_domain,vlan_name,vlan_type,vlan_mtu FROM vlans WHERE `device_id` = ?", array($device_id));
|
||||||
$total_vlans = count($vlans);
|
$total_vlans = count($vlans);
|
||||||
$output = array("status" => "ok", "count" => $total_vlans, "vlans" => array($vlans));
|
$output = array("status" => "ok", "count" => $total_vlans, "vlans" => $vlans);
|
||||||
} else {
|
} else {
|
||||||
$code = 404;
|
$code = 404;
|
||||||
$output = array("status" => "error", "Device $hostname not found");
|
$output = array("status" => "error", "Device $hostname not found");
|
||||||
|
|||||||
Reference in New Issue
Block a user