@hlfan commented on this pull request.
> @@ -60,7 +69,7 @@
.then(response => response.json())
.then(({ paths }) => {
if (!paths || paths.length === 0) throw new Error();
- return _processDirections(paths[0]);
+ return _processDirections(paths[0], points, vehicleType);
I'd use this opportunity to pull the credit out of the private function too:
```javascript
const meta = {
credit: "GraphHopper",
creditlink: "https://www.graphhopper.com/",
demolink: demoLink
};
```
```suggestion
return { ..._processDirections(paths[0]), ...meta };
```
That's what I originally was thinking.
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6693#pullrequestreview-3645193430
You are receiving this because you are subscribed to this thread.
Message ID:
<openstreetmap/openstreetmap-website/pull/6693/review/[email protected]>_______________________________________________
rails-dev mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/rails-dev