mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Added a response code when things are ok - oops
This commit is contained in:
@ -468,6 +468,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);
|
||||||
|
$code = 200;
|
||||||
$output = array("status" => "ok", "count" => $total_vlans, "vlans" => $vlans);
|
$output = array("status" => "ok", "count" => $total_vlans, "vlans" => $vlans);
|
||||||
} else {
|
} else {
|
||||||
$code = 404;
|
$code = 404;
|
||||||
|
Reference in New Issue
Block a user