summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/hafas-m4
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',