get_travel_distance: intermediate: Handle destination renames in sanity check
Also related to #160
This commit is contained in:
parent
39fb04baf0
commit
5192d997de
1 changed files with 6 additions and 1 deletions
|
@ -1199,7 +1199,12 @@ sub get_travel_distance {
|
||||||
= before_incl { ( $_->[1] and $_->[1] == $to_eva ) or $_->[0] eq $to }
|
= before_incl { ( $_->[1] and $_->[1] == $to_eva ) or $_->[0] eq $to }
|
||||||
@route;
|
@route;
|
||||||
|
|
||||||
if ( @route < 2 or $route[-1][0] ne $to ) {
|
if (
|
||||||
|
@route < 2
|
||||||
|
or ( $route[-1][0] ne $to
|
||||||
|
and ( not $route[-1][1] or $route[-1][1] != $to_eva ) )
|
||||||
|
)
|
||||||
|
{
|
||||||
|
|
||||||
# I AM ERROR
|
# I AM ERROR
|
||||||
return ( 0, 0, $distance_beeline );
|
return ( 0, 0, $distance_beeline );
|
||||||
|
|
Loading…
Reference in a new issue