X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/3d3b2b47964ec91ef1ab1946b7258a06665caced..248b5fa1aefb8c7b4ece818ad3720992f2487fe2:/app/assets/javascripts/leaflet.key.js diff --git a/app/assets/javascripts/leaflet.key.js b/app/assets/javascripts/leaflet.key.js index 937d9b052..45d22feed 100644 --- a/app/assets/javascripts/leaflet.key.js +++ b/app/assets/javascripts/leaflet.key.js @@ -16,7 +16,10 @@ L.OSM.key = function (options) { function shown() { map.on("zoomend baselayerchange", update); - $section.load("/key", update); + fetch("/key") + .then(r => r.text()) + .then(html => { $section.html(html); }) + .then(update); } function hidden() {