[openstreetmap/openstreetmap-website] Query tool: hovering over relations sometimes unresponsive (#1608)
mmd
notifications at github.com
Thu Aug 10 18:32:31 UTC 2017
Suggested fix:
```javascript
diff --git a/app/assets/javascripts/index/query.js b/app/assets/javascripts/index/query.js
index 018aedf..7ac613d 100644
--- a/app/assets/javascripts/index/query.js
+++ b/app/assets/javascripts/index/query.js
@@ -146,7 +146,7 @@ OSM.Query = function(map) {
if (feature.type === "node" && feature.lat && feature.lon) {
geometry = L.circleMarker([feature.lat, feature.lon], featureStyle);
- } else if (feature.type === "way" && feature.geometry) {
+ } else if (feature.type === "way" && feature.geometry && feature.geometry.length > 0) {
geometry = L.polyline(feature.geometry.filter(function (point) {
return point !== null;
}).map(function (point) {
```
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/1608#issuecomment-321636152
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20170810/636bfd38/attachment-0001.html>
More information about the rails-dev
mailing list