summaryrefslogtreecommitdiff
path: root/lib/Travel/Status
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Travel/Status')
-rw-r--r--lib/Travel/Status/DE/HAFAS/Services.pm.PL7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/Travel/Status/DE/HAFAS/Services.pm.PL b/lib/Travel/Status/DE/HAFAS/Services.pm.PL
index 97eabef..638bd53 100644
--- a/lib/Travel/Status/DE/HAFAS/Services.pm.PL
+++ b/lib/Travel/Status/DE/HAFAS/Services.pm.PL
@@ -46,7 +46,12 @@ sub load_instance {
for ( 1 .. $skipped ) {
push( @{ $ret{productbits} }, [ "_", undef ] );
}
- push( @{ $ret{productbits} }, [ $p->{id}, $p->{name} ] );
+ if ( $p->{name} ) {
+ push( @{ $ret{productbits} }, [ $p->{id}, $p->{name} ] );
+ }
+ else {
+ push( @{ $ret{productbits} }, $p->{id} );
+ }
}
else {
$skipped += 1;