log train number when encountering a timestamp error

This commit is contained in:
Daniel Friesel 2020-04-16 04:55:04 +02:00
parent e5f273ced3
commit d66cf00d9d

View file

@ -807,7 +807,8 @@ sub startup {
my $tx = $db->begin;
if ( defined $train and not $train->arrival and not $force ) {
die("Train has no arrival timestamp\n");
my $train_no = $train->train_no;
die("Train ${train_no} has no arrival timestamp\n");
}
elsif ( defined $train and $train->arrival ) {