Skip to content

Commit

Permalink
Fixed bug in the statistics distribution diagram, transferring string…
Browse files Browse the repository at this point in the history
… values instead of integers
  • Loading branch information
magicsunday committed Oct 10, 2020
1 parent 4aa632f commit 9b64441
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/Statistics/Google/ChartDistribution.php
Expand Up @@ -215,9 +215,9 @@ private function getMarriageChartData(): array
$country_code = $this->country_to_iso3166[$place->country];

if (array_key_exists($country_code, $surn_countries)) {
$surn_countries[$country_code] += $place->tot;
$surn_countries[$country_code] += (int) $place->tot;
} else {
$surn_countries[$country_code] = $place->tot;
$surn_countries[$country_code] = (int) $place->tot;
}
}
}
Expand Down Expand Up @@ -304,9 +304,9 @@ private function getIndivdualChartData(): array
$country_code = $this->country_to_iso3166[$place->country];

if (array_key_exists($country_code, $surn_countries)) {
$surn_countries[$country_code] += $place->tot;
$surn_countries[$country_code] += (int) $place->tot;
} else {
$surn_countries[$country_code] = $place->tot;
$surn_countries[$country_code] = (int) $place->tot;
}
}
}
Expand Down

0 comments on commit 9b64441

Please sign in to comment.