diff options
author | Birte Kristina Friesel <derf@finalrewind.org> | 2024-04-28 11:11:47 +0200 |
---|---|---|
committer | Birte Kristina Friesel <derf@finalrewind.org> | 2024-04-28 11:11:47 +0200 |
commit | a0c313fcce393792c6552a1f0d5f00b034466c13 (patch) | |
tree | 2129f088d2ced602a02a0cc67e8195ddb9924d01 /lib/Travel/Status/DE/DBWagenreihung.pm | |
parent | 11a58c8e0292b45694759a07bd150a0fdb852a8f (diff) |
Do not mis-detect powercars as Link I
Diffstat (limited to 'lib/Travel/Status/DE/DBWagenreihung.pm')
-rw-r--r-- | lib/Travel/Status/DE/DBWagenreihung.pm | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/Travel/Status/DE/DBWagenreihung.pm b/lib/Travel/Status/DE/DBWagenreihung.pm index 64fe913..ea14ec9 100644 --- a/lib/Travel/Status/DE/DBWagenreihung.pm +++ b/lib/Travel/Status/DE/DBWagenreihung.pm @@ -709,7 +709,13 @@ sub wagongroup_subtype { # Less than two wagons are generally inconclusive. # Exception: BR 631 (Link I) only has a single wagon - if ( $ml{ $likelihood[0] } < 2 and $likelihood[0] ne '631' ) { + if ( + $ml{ $likelihood[0] } < 2 + and not($likelihood[0] eq '631' + and @wagons == 1 + and substr( $wagons[0]->uic_id, 0, 2 ) eq '95' ) + ) + { return undef; } |