#13244 fixed DivisionByZeroError

This commit is contained in:
Daniel Cebrian 2024-04-02 13:31:57 +02:00
parent ac3461fc04
commit 8485618446
1 changed files with 1 additions and 1 deletions

View File

@ -4100,7 +4100,7 @@ function fullscale_data(
$data['sum'.$series_suffix]['min'] = $min_value_total;
$data['sum'.$series_suffix]['max'] = $max_value_total;
$data['sum'.$series_suffix]['avg'] = 0;
if (isset($count_data_total) === true) {
if (isset($count_data_total) === true && $count_data_total > 0) {
$data['sum'.$series_suffix]['avg'] = ($sum_data_total / $count_data_total);
}
}