mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
refactor: Remove inappropriate usages of truncate() (#5028)
Where truncate() is used as substr(), replace with substr()
This commit is contained in:
committed by
Neil Lathwood
parent
e469aa97b0
commit
a83e126b40
@@ -42,7 +42,7 @@ if ($device['os'] != 'Snom') {
|
||||
$rrd_def = array();
|
||||
$fields = array();
|
||||
foreach ($oids as $oid) {
|
||||
$oid_ds = truncate($oid, 19, '');
|
||||
$oid_ds = substr($oid, 0, 19);
|
||||
$rrd_def[] = "DS:$oid_ds:COUNTER:600:U:100000000000";
|
||||
$fields[$oid] = isset($data[0][$oid]) ? $data[0][$oid] : 'U';
|
||||
}
|
||||
|
Reference in New Issue
Block a user