Minor change in my_temp function

default to Celsius
This commit is contained in:
bergware
2017-10-28 18:52:45 +02:00
parent 85f30efec3
commit 04d88d2e83

View File

@@ -50,7 +50,7 @@ function my_temp($value) {
global $display;
$unit = $display['unit'];
$number = $display['number'];
return is_numeric($value) ? (($unit=='C' ? str_replace('.', $number[0], $value) : round(9/5*$value+32))." $unit") : $value;
return is_numeric($value) ? (($unit=='F' ? round(9/5*$value+32) : str_replace('.', $number[0], $value))." $unit") : $value;
}
function my_disk($name) {
return ucfirst(preg_replace('/^(disk|cache|parity)(\d+)/','$1 $2',$name));