From bceb6e1dfa353427986921bb1ea1c7e31ec5dd28 Mon Sep 17 00:00:00 2001 From: Rosiak Date: Wed, 15 Jul 2015 13:11:40 +0200 Subject: [PATCH] Adjust code to Best Practice MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - More adjustments. Done after the big cleanup PR I’ve gone through discovery and polling folders. --- includes/discovery/os/fiberhome.inc.php | 1 - includes/discovery/power/rfc1628.inc.php | 2 -- includes/polling/os/akcp.inc.php | 2 -- includes/polling/os/deltaups.inc.php | 2 -- includes/polling/os/engenius.inc.php | 1 - includes/polling/os/powerware.inc.php | 2 -- includes/polling/os/sentry3.inc.php | 2 -- includes/polling/os/unix.inc.php | 2 -- 8 files changed, 14 deletions(-) diff --git a/includes/discovery/os/fiberhome.inc.php b/includes/discovery/os/fiberhome.inc.php index e4add9aa6e..5f58298587 100644 --- a/includes/discovery/os/fiberhome.inc.php +++ b/includes/discovery/os/fiberhome.inc.php @@ -9,4 +9,3 @@ if (!$os){ $os = "fiberhome"; } } -?> \ No newline at end of file diff --git a/includes/discovery/power/rfc1628.inc.php b/includes/discovery/power/rfc1628.inc.php index 42a2f0b196..8816ff9b4c 100644 --- a/includes/discovery/power/rfc1628.inc.php +++ b/includes/discovery/power/rfc1628.inc.php @@ -55,5 +55,3 @@ if (isset($config['modules_compat']['rfc1628'][$device['os']]) && $config['modul discover_sensor($valid['sensor'], 'power', $device, $current_oid, $index, $type, $descr, '1', '1', NULL, NULL, NULL, NULL, $current); } } - -?> diff --git a/includes/polling/os/akcp.inc.php b/includes/polling/os/akcp.inc.php index 99bf7cdd6c..724eddfd88 100644 --- a/includes/polling/os/akcp.inc.php +++ b/includes/polling/os/akcp.inc.php @@ -2,5 +2,3 @@ $hardware = trim(snmp_get($device, "1.3.6.1.4.1.3854.1.1.6.0", "-OQv", "", ""),'"'); $hardware .= ' ' . trim(snmp_get($device, "1.3.6.1.4.1.3854.1.1.8.0", "-OQv", "", ""),'" '); - -?> \ No newline at end of file diff --git a/includes/polling/os/deltaups.inc.php b/includes/polling/os/deltaups.inc.php index 8f32b05c84..fe66ba5597 100644 --- a/includes/polling/os/deltaups.inc.php +++ b/includes/polling/os/deltaups.inc.php @@ -9,5 +9,3 @@ $hardware .= ' ' . trim(snmp_get($device, "dupsIdentModel.0", "-OQv", "DeltaUPS- $version = trim(snmp_get($device, "dupsIdentUPSSoftwareVersion.0", "-OQv", "DeltaUPS-MIB", ""),'" '); # DeltaUPS-MIB::dupsIdentAgentSoftwareVersion.0 = STRING: "2.0h " - -?> \ No newline at end of file diff --git a/includes/polling/os/engenius.inc.php b/includes/polling/os/engenius.inc.php index f8d99ee40d..e090701954 100644 --- a/includes/polling/os/engenius.inc.php +++ b/includes/polling/os/engenius.inc.php @@ -41,4 +41,3 @@ if(is_numeric($mode)) { break; } } -?> diff --git a/includes/polling/os/powerware.inc.php b/includes/polling/os/powerware.inc.php index 2bd017229d..5a7bcc0547 100644 --- a/includes/polling/os/powerware.inc.php +++ b/includes/polling/os/powerware.inc.php @@ -7,5 +7,3 @@ $hardware .= ' ' . trim(snmp_get($device, "xupsIdentModel.0", "-OQv", "XUPS-MIB" # XUPS-MIB::xupsIdentSoftwareVersion.0 = STRING: " FP: 2.01 INV: 2.01 NET: 3.60 " $version = trim(snmp_get($device, "xupsIdentSoftwareVersion.0", "-OQv", "XUPS-MIB", ""),'" '); - -?> \ No newline at end of file diff --git a/includes/polling/os/sentry3.inc.php b/includes/polling/os/sentry3.inc.php index 638a3dafcf..5f3e64ea84 100644 --- a/includes/polling/os/sentry3.inc.php +++ b/includes/polling/os/sentry3.inc.php @@ -9,5 +9,3 @@ $serial = snmp_get($device, "towerProductSN.1", "-Ovq", "Sentry3-MIB"); $version = snmp_get($device, "systemVersion.0", "-Ovq", "Sentry3-MIB"); $version = preg_split('/Sentry\ (Switched|Smart)\ CDU\ Version/', $version); $version = $version[1]; - -?> diff --git a/includes/polling/os/unix.inc.php b/includes/polling/os/unix.inc.php index 7f6e30f9ad..86b4f7bf92 100644 --- a/includes/polling/os/unix.inc.php +++ b/includes/polling/os/unix.inc.php @@ -125,5 +125,3 @@ elseif ($device['os'] == "pfsense") { $version = $output[2]; $hardware = $output[6]; } - -?>