summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2020-11-21 15:39:21 +0100
committerDaniel Friesel <derf@finalrewind.org>2020-11-21 15:39:21 +0100
commit0addce7bff7dd87c663e09217659dc0555d93453 (patch)
tree7ea0a26140da91f560a82adfe20e345324059758 /templates
parentccfdd8007e136d5d98652d415dda8eb595a2ada9 (diff)
month overview: distinguish between no stats and no journeys1.18.10
Diffstat (limited to 'templates')
-rw-r--r--templates/_history_months_for_year.html.ep4
1 files changed, 3 insertions, 1 deletions
diff --git a/templates/_history_months_for_year.html.ep b/templates/_history_months_for_year.html.ep
index c6a64de..1d035ab 100644
--- a/templates/_history_months_for_year.html.ep
+++ b/templates/_history_months_for_year.html.ep
@@ -4,7 +4,9 @@
% for my $month (journeys->get_months_for_year(uid => current_user->{id}, year => $year)) {
% if (defined $month->[2]) {
<a class="collection-item" href="/history/<%= $month->[0] %>"><%= $month->[1] %>
- <span class="secondary-content"><%= sprintf('%.f', $month->[2]{km_route}) %> km</span>
+ % if (defined $month->[2]{km_route}) {
+ <span class="secondary-content"><%= sprintf('%.f', $month->[2]{km_route}) %> km</span>
+ % }
</a>
% }
% else {