[openstreetmap/openstreetmap-website] Fixed displacing points specified from context menu (PR #4904)

Anton Khorev notifications at github.com
Fri Aug 9 03:27:26 UTC 2024


@AntonKhorev commented on this pull request.



> @@ -5,6 +5,7 @@
 OSM.Directions = function (map) {
   var awaitingRoute; // true if we've asked the engine for a route and are waiting to hear back
   var chosenEngine;
+  var coordinatesRegularExpression = "([+-]?\\d+(\\.\\d*)?)(?:\\s+|\\s*[/,]\\s*)([+-]?\\d+(\\.\\d*)?)";

Why does this expression have capture groups if they are not used? Instead there's `endpoint.value.split(/[/,]/)`.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/4904#discussion_r1710640333
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/4904/review/2229209978 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20240808/5a8a10ab/attachment.htm>


More information about the rails-dev mailing list