X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/c3f0dc8969aa41f07cd45563b65c4493ac187bde..87363858cb4e9cff9b5c29ac6e95425c5c3fab8b:/app/assets/javascripts/index/directions/graphhopper.js diff --git a/app/assets/javascripts/index/directions/graphhopper.js b/app/assets/javascripts/index/directions/graphhopper.js index 729618f2d..b3194d16c 100644 --- a/app/assets/javascripts/index/directions/graphhopper.js +++ b/app/assets/javascripts/index/directions/graphhopper.js @@ -1,5 +1,5 @@ (function () { - function GraphHopperEngine(id, vehicleType) { + function GraphHopperEngine(modeId, vehicleType) { const GH_INSTR_MAP = { "-3": 7, // sharp left "-2": 6, // left @@ -47,7 +47,8 @@ } return { - id: id, + mode: modeId, + provider: "graphhopper", creditline: "GraphHopper", draggable: false, @@ -73,7 +74,7 @@ }; } - OSM.Directions.addEngine(new GraphHopperEngine("graphhopper_car", "car"), true); - OSM.Directions.addEngine(new GraphHopperEngine("graphhopper_bicycle", "bike"), true); - OSM.Directions.addEngine(new GraphHopperEngine("graphhopper_foot", "foot"), true); + OSM.Directions.addEngine(new GraphHopperEngine("car", "car"), true); + OSM.Directions.addEngine(new GraphHopperEngine("bicycle", "bike"), true); + OSM.Directions.addEngine(new GraphHopperEngine("foot", "foot"), true); }());