1
0
Fork 0

Revert "Fix logic error in SID discontinuity logic"

This reverts commit c39fddb05b.
This commit is contained in:
Jonathan Redpath 2022-05-19 21:38:22 +01:00
parent c39fddb05b
commit ebfaa28637

View file

@ -77,7 +77,7 @@ var A320RouteManagerDelegate = {
me.flightplan.insertWaypoints(wps, 1);
for (var wpIdx = 0; wpIdx < me.flightplan.getPlanSize(); wpIdx = wpIdx + 1) {
if (me.flightplan.getWP(wpIdx).wp_type == "vectors" and me.flightplan.getWP(wpIdx + 1) != nil and me.flightplan.getWP(wpIdx + 1).wp_type != "discontinuity") {
if (me.flightplan.getWP(wpIdx).wp_type == "vectors" and (me.flightplan.getWP(wpIdx + 1) == nil or me.flightplan.getWP(wpIdx + 1).wp_type != "discontinuity")) {
me.flightplan.insertWP(createDiscontinuity(), wpIdx + 1);
}
}