fix time with routing issue

This commit is contained in:
vcoppe
2024-07-18 10:43:38 +02:00
parent 44afe6cc76
commit d6c0e403f9
2 changed files with 8 additions and 5 deletions

View File

@@ -799,7 +799,7 @@ export class TrackSegment extends GPXTreeLeaf {
if (trkpt[end + 1].time === undefined) {
trkpt.splice(end + 1, 0, ...withTimestamps(trkpt.splice(end + 1), speed, last, startTime));
} else if (last !== undefined && trkpt[end + 1].time < last.time) {
points = withShiftedAndCompressedTimestamps(points, speed, 1, last);
trkpt.splice(end + 1, 0, ...withShiftedAndCompressedTimestamps(trkpt.splice(end + 1), speed, 1, last));
}
}
}