diff options
Diffstat (limited to 'modern/src/map/MapRoutePath.js')
-rw-r--r-- | modern/src/map/MapRoutePath.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modern/src/map/MapRoutePath.js b/modern/src/map/MapRoutePath.js index d2d6827c..7971e3d3 100644 --- a/modern/src/map/MapRoutePath.js +++ b/modern/src/map/MapRoutePath.js @@ -71,7 +71,7 @@ const MapRoutePath = ({ positions }) => { }, }); if (coordinates.length) { - const bounds = coordinates.reduce((bounds, item) => bounds.extend(item), new maplibregl.LngLatBounds(coordinates[0], coordinates[0])); + const bounds = coordinates.reduce((bounds, item) => bounds.extend(item), new maplibregl.LngLatBounds(coordinates[0], coordinates[1])); const canvas = map.getCanvas(); map.fitBounds(bounds, { padding: Math.min(canvas.width, canvas.height) * 0.1, |