diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Travel/Status/DE/DBWagenreihung.pm | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/lib/Travel/Status/DE/DBWagenreihung.pm b/lib/Travel/Status/DE/DBWagenreihung.pm index cbc30de..99291e3 100644 --- a/lib/Travel/Status/DE/DBWagenreihung.pm +++ b/lib/Travel/Status/DE/DBWagenreihung.pm @@ -83,15 +83,14 @@ sub get_wagonorder { number => $train_number, time => $time }; - my ( $content, $err ) = $self->get_with_cache( - $cache, - $api_base . '?' - . join( '&', - map { $_ . '=' . $self->{param}{$_} } keys %{ $self->{param} } ) - ); + my $url + = $api_base . '?' + . join( '&', + map { $_ . '=' . $self->{param}{$_} } keys %{ $self->{param} } ); + my ( $content, $err ) = $self->get_with_cache( $cache, $url ); if ($err) { - $self->{errstr} = "Failed to fetch station data: $err"; + $self->{errstr} = "GET $url: $err"; return; } $json = $self->{from_json} = $self->{json}->utf8->decode($content); |