Merge pull request #2940 from laf/issue-2921

Updated device_by_id_cache() to convert IP column
This commit is contained in:
Daniel Preussker
2016-02-05 19:37:36 +00:00

View File

@ -315,6 +315,7 @@ function device_by_id_cache($device_id, $refresh = '0') {
} }
else { else {
$device = dbFetchRow("SELECT * FROM `devices` WHERE `device_id` = ?", array($device_id)); $device = dbFetchRow("SELECT * FROM `devices` WHERE `device_id` = ?", array($device_id));
$device['ip'] = inet6_ntop($device['ip']);
$cache['devices']['id'][$device_id] = $device; $cache['devices']['id'][$device_id] = $device;
} }
return $device; return $device;