Skip to content

Commit 64b3444

Browse files
Merge pull request #1196 from Kobzol/graphs-skip-empty
Hide charts with no data in graphs page
2 parents 3381e7e + 45397db commit 64b3444

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

site/src/selector.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -473,9 +473,9 @@ impl StatisticSeries {
473473
.get_pstats(&sids, &aids)
474474
.await
475475
.into_iter()
476-
.enumerate()
477-
.map(|(idx, points)| {
478-
let &&(benchmark, profile, scenario, metric) = &statistic_descriptions[idx];
476+
.zip(&statistic_descriptions)
477+
.filter(|(points, _)| points.iter().any(|value| value.is_some()))
478+
.map(|(points, &&(benchmark, profile, scenario, metric))| {
479479
SeriesResponse {
480480
series: StatisticSeries {
481481
artifact_ids: ArtifactIdIter::new(artifact_ids.clone()),

0 commit comments

Comments
 (0)