From 70b8717c3025f09550cf144e838ee0313346ef72 Mon Sep 17 00:00:00 2001 From: Birte Kristina Friesel Date: Wed, 6 Mar 2024 18:24:19 +0100 Subject: train_details: handle undefined $wr->direction --- templates/_train_details.html.ep | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'templates') diff --git a/templates/_train_details.html.ep b/templates/_train_details.html.ep index ccdb70a..4943ba2 100644 --- a/templates/_train_details.html.ep +++ b/templates/_train_details.html.ep @@ -116,7 +116,7 @@ % if (my $wr = $departure->{wr}) {
% my @wagons = $wr->wagons; -% my $direction = $wr->direction == 100 ? '→' : '←'; +% my $direction = $wr->direction ? $wr->direction == 100 ? '→' : '←' : q{}; % if ($departure->{direction}) { % $direction = $departure->{direction} eq 'l' ? '◀' : '▶'; % if (($departure->{direction} eq 'l' ? 0 : 100) != $wr->direction) { -- cgit v1.2.3