Add some asserts in stats.

This commit is contained in:
John Preston
2025-08-14 16:30:11 +04:00
parent 4cefc21819
commit 96360619e1
2 changed files with 4 additions and 0 deletions
@@ -83,6 +83,8 @@ PiePartData PiePartsPercentageByIndices(
for (const auto &line : chartData.lines) {
auto sum = ChartValue(0);
for (auto i = xIndices.min; i <= xIndices.max; i++) {
const auto index = int(base::SafeRound(i));
Assert(index >= 0 && index < line.y.size());
sum += line.y[i];
}
if (linesFilter) {