2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-03-03 23:06:37 +00:00

98_DOIF.pm: svg card: fixed automatic scaling min/max problem

git-svn-id: https://svn.fhem.de/fhem/trunk@24274 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
Damian 2021-04-18 16:40:42 +00:00
parent 92f6833bb0
commit 0ad4cf03ec

View File

@ -4540,8 +4540,8 @@ sub card
## if (defined $plot and $plot eq "autoscale" and $minVal ne $maxVal) {
if (!defined $plot and $minVal ne $maxVal) {
$minPlot=$minVal;
$maxPlot=$maxVal;
$minPlot=($val < $minVal ? $val : $minVal);
$maxPlot=($val > $maxVal ? $val : $maxVal);
} else {
$minPlot=($min < 0 and $minVal > 0) ? 0:$min;
$maxPlot=($max > 0 and $maxVal < 0) ? 0:$max;