[openstreetmap/openstreetmap-website] Take entrances into account for routing start and end points (PR #7017)

Sarah Hoffmann notifications at github.com
Wed Apr 22 06:57:19 UTC 2026


@lonvia commented on this pull request.



> +      let ll = null;
+      // if the place has entrances, use their location in preference
+      if (json[0].entrances) {
+        for (const e of json[0].entrances) {
+          if (e.type === "main") {
+            ll = e;
+            break;
+          }
+          if (!ll && e.type === "yes") {
+            ll = e;
+          }
+        }
+      }
+      if (!ll) {
+        ll = json[0];
+      }

If using Pablo' suggestion (or nay other) is the only blocker to merging this, I'm happy to change. I really don't care either way. Right now, let's see if this is acceptable at all.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/7017?email_source=notifications&email_token=AAK2OLOENTUATYP4URGDNGT4XBUM7A5CNFSNUABKM5UWIORPF5TWS5BNNB2WEL2QOVWGYUTFOF2WK43UKJSXM2LFO4XTIMJVGI3DENRVGQ42M4TFMFZW63VKON2WE43DOJUWEZLEUVSXMZLOOS6XA4S7OJSXM2LFO5PW433UNFTGSY3BORUW63TTL5RWY2LDNM#discussion_r3122097433
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/7017/review/4152626549 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20260421/80ad9c72/attachment.htm>


More information about the rails-dev mailing list