mirror of
https://gitlab.com/mobicoop/v3/service/matcher.git
synced 2026-01-01 08:12:40 +00:00
wip - create journeys - no tests yet
This commit is contained in:
@@ -164,12 +164,14 @@ export class GraphhopperGeorouter implements GeorouterPort {
|
||||
points: [[number, number]],
|
||||
snappedWaypoints: [[number, number]],
|
||||
): number[] => {
|
||||
const indices = snappedWaypoints.map((waypoint) =>
|
||||
points.findIndex(
|
||||
(point) => point[0] == waypoint[0] && point[1] == waypoint[1],
|
||||
),
|
||||
const indices: number[] = snappedWaypoints.map(
|
||||
(waypoint: [number, number]) =>
|
||||
points.findIndex(
|
||||
(point) => point[0] == waypoint[0] && point[1] == waypoint[1],
|
||||
),
|
||||
);
|
||||
if (indices.find((index) => index == -1) === undefined) return indices;
|
||||
if (indices.find((index: number) => index == -1) === undefined)
|
||||
return indices;
|
||||
const missedWaypoints = indices
|
||||
.map(
|
||||
(value, index) =>
|
||||
|
||||
Reference in New Issue
Block a user