diff options
author | Daniel Friesel <derf@finalrewind.org> | 2015-09-11 15:35:40 +0200 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2015-09-11 15:35:40 +0200 |
commit | 53a32113d048c2ab7b98771ae23e470d562bb40a (patch) | |
tree | 67e7681afed0131ee0e9b122786eea789c8dd388 /bin/hafas-m | |
parent | e51bb2b0dd1727ba5a799ed63ad40eeae66fd1db (diff) |
re-add mot support (basics at least)
Diffstat (limited to 'bin/hafas-m')
-rwxr-xr-x | bin/hafas-m | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/hafas-m b/bin/hafas-m index 5dea42e..f279b04 100755 --- a/bin/hafas-m +++ b/bin/hafas-m @@ -18,6 +18,7 @@ my $types = q{}; my $language; my $developer_mode; my ( $list_services, $service, $hafas_url ); +my @excluded_mots; my @output; @@ -50,6 +51,7 @@ if ($list_services) { for my $type ( split( qr{,}, $types ) ) { if ( substr( $type, 0, 1 ) eq q{!} ) { $train_type{ substr( $type, 1 ) } = 0; + push( @excluded_mots, substr( $type, 1 ) ); } else { $train_type{$type} = 1; @@ -59,7 +61,7 @@ for my $type ( split( qr{,}, $types ) ) { my $status = Travel::Status::DE::HAFAS->new( date => $date, language => $language, - mot => \%train_type, + excluded_mots => \@excluded_mots, station => shift || show_help(1), time => $time, mode => $arrivals ? 'arr' : 'dep', |