]> git.openstreetmap.org Git - rails.git/commitdiff
Recognise locations in the hash correctly
authorTom Hughes <tom@compton.nu>
Tue, 6 Aug 2013 09:23:51 +0000 (10:23 +0100)
committerTom Hughes <tom@compton.nu>
Tue, 6 Aug 2013 09:23:51 +0000 (10:23 +0100)
app/assets/javascripts/osm.js.erb

index 409cda8d84fd51426c0a0e93feda73a297e38d80..e414d26ffa0a1b783420212781e0516a4c0fdd40 100644 (file)
@@ -75,7 +75,7 @@ OSM = {
     var hash = OSM.parseHash(location.hash);
 
     // Decide on a map starting position. Various ways of doing this.
-    if (hash.lat && hash.lon) {
+    if (hash.center) {
       mapParams.lon = hash.center.lng;
       mapParams.lat = hash.center.lat;
       mapParams.zoom = hash.zoom;