diff options
author | Birte Kristina Friesel <derf@finalrewind.org> | 2024-07-30 13:20:46 +0200 |
---|---|---|
committer | Birte Kristina Friesel <derf@finalrewind.org> | 2024-07-30 13:20:46 +0200 |
commit | 124b68f3a2889aa411f5af995015db9a9bac133d (patch) | |
tree | 09756227c3447478abfa578566090097839d99b9 /lib/Travel/Status/DE/DBWagenreihung | |
parent | efb13e90e8352c54741832a6f5d950b011c79998 (diff) |
Add trains accessor
Diffstat (limited to 'lib/Travel/Status/DE/DBWagenreihung')
-rw-r--r-- | lib/Travel/Status/DE/DBWagenreihung/Group.pm | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/Travel/Status/DE/DBWagenreihung/Group.pm b/lib/Travel/Status/DE/DBWagenreihung/Group.pm index b6848ab..3da0670 100644 --- a/lib/Travel/Status/DE/DBWagenreihung/Group.pm +++ b/lib/Travel/Status/DE/DBWagenreihung/Group.pm @@ -89,6 +89,8 @@ sub new { train_no => $json{transport}{number}, }; + $ref->{train} = $ref->{train_type} . ' ' . $ref->{train_no}; + $ref->{sectors} = [ uniq grep { defined } map { $_->{platformPosition}{sector} } @{ $json{vehicles} // [] } |