summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/DBInfoscreen/Controller/Stationboard.pm6
-rw-r--r--lib/DBInfoscreen/Helper/HAFAS.pm6
2 files changed, 7 insertions, 5 deletions
diff --git a/lib/DBInfoscreen/Controller/Stationboard.pm b/lib/DBInfoscreen/Controller/Stationboard.pm
index 2951ab9..e8a6721 100644
--- a/lib/DBInfoscreen/Controller/Stationboard.pm
+++ b/lib/DBInfoscreen/Controller/Stationboard.pm
@@ -60,7 +60,7 @@ sub handle_no_results {
}
elsif ($hafas) {
$self->render_later;
- my $service = 'DB';
+ my $service = 'VRN';
if ( $hafas ne '1' and Travel::Status::DE::HAFAS::get_service($hafas) )
{
$service = $hafas;
@@ -381,7 +381,7 @@ sub get_results_p {
);
}
if ( $opt{hafas} ) {
- my $service = 'DB';
+ my $service = 'VRN';
if ( $opt{hafas} ne '1'
and Travel::Status::DE::HAFAS::get_service( $opt{hafas} ) )
{
@@ -2332,7 +2332,7 @@ sub stations_by_coordinates {
return;
}
- my $service = 'DB';
+ my $service = 'VRN';
if ( $hafas
and $hafas ne '1'
and Travel::Status::DE::HAFAS::get_service($hafas) )
diff --git a/lib/DBInfoscreen/Helper/HAFAS.pm b/lib/DBInfoscreen/Helper/HAFAS.pm
index 0400d59..fe0caa5 100644
--- a/lib/DBInfoscreen/Helper/HAFAS.pm
+++ b/lib/DBInfoscreen/Helper/HAFAS.pm
@@ -50,7 +50,7 @@ sub get_route_p {
if ( $opt{trip_id} ) {
$hafas_promise = Travel::Status::DE::HAFAS->new_p(
- service => $opt{service},
+ service => $opt{service} // 'VRN',
journey => {
id => $opt{trip_id},
},
@@ -69,6 +69,7 @@ sub get_route_p {
}
$hafas_promise //= Travel::Status::DE::HAFAS->new_p(
+ service => $opt{service} // 'VRN',
journeyMatch => $opt{train_req} =~ s{^- }{}r,
datetime => ( $opt{train} ? $opt{train}->start : $opt{datetime} ),
language => $opt{language},
@@ -99,6 +100,7 @@ sub get_route_p {
}
return Travel::Status::DE::HAFAS->new_p(
+ service => $opt{service} // 'VRN',
journey => {
id => $result->id,
},
@@ -264,7 +266,7 @@ sub get_polyline_p {
my $trip_id = $opt{id};
my $line = $opt{line};
- my $service = $opt{service};
+ my $service = $opt{service} // 'VRN';
my $promise = Mojo::Promise->new;
Travel::Status::DE::HAFAS->new_p(