get_connecting_trains_p: leave loops when done
This commit is contained in:
parent
383ec3feb3
commit
9f06b52a00
1 changed files with 3 additions and 1 deletions
|
@ -279,7 +279,7 @@ sub get_connecting_trains_p {
|
||||||
eval {
|
eval {
|
||||||
for my $iris_train (@iris_trains) {
|
for my $iris_train (@iris_trains) {
|
||||||
if ( $iris_train->[0]->departure_is_cancelled ) {
|
if ( $iris_train->[0]->departure_is_cancelled ) {
|
||||||
continue;
|
next;
|
||||||
}
|
}
|
||||||
for my $hafas_train (@hafas_trains) {
|
for my $hafas_train (@hafas_trains) {
|
||||||
if ( $hafas_train->{line}{fahrtNr}
|
if ( $hafas_train->{line}{fahrtNr}
|
||||||
|
@ -304,8 +304,10 @@ sub get_connecting_trains_p {
|
||||||
$iris_train->[2]->add( minutes =>
|
$iris_train->[2]->add( minutes =>
|
||||||
$iris_train->[0]->arrival_delay );
|
$iris_train->[0]->arrival_delay );
|
||||||
}
|
}
|
||||||
|
last;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
last;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue