Skip to content

Commit

Permalink
switch to intval() over floor() for #4548
Browse files Browse the repository at this point in the history
  • Loading branch information
TheWitness committed Feb 9, 2022
1 parent 0503441 commit f26793d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/functions.php
Expand Up @@ -5244,7 +5244,7 @@ function get_timeinstate($host) {
}

function get_uptime($host) {
return ($host['snmp_sysUpTimeInstance'] > 0) ? get_daysfromtime(floor($host['snmp_sysUpTimeInstance']/100)) : __('N/A');
return ($host['snmp_sysUpTimeInstance'] > 0) ? get_daysfromtime(intval($host['snmp_sysUpTimeInstance']/100)) : __('N/A');
}

function get_daysfromtime($time, $secs = false, $pad = '', $format = DAYS_FORMAT_SHORT, $all = false) {
Expand Down

0 comments on commit f26793d

Please sign in to comment.