Don't pass the hash when routing an empty search query
authorTom Hughes <tom@compton.nu>
Mon, 13 Oct 2014 13:04:19 +0000 (14:04 +0100)
committerTom Hughes <tom@compton.nu>
Mon, 13 Oct 2014 13:04:19 +0000 (14:04 +0100)
Fixes #793

app/assets/javascripts/index.js

index c066f89..a259954 100644 (file)
@@ -337,7 +337,7 @@ $(document).ready(function () {
     if (query) {
       OSM.router.route("/search?query=" + encodeURIComponent(query) + OSM.formatHash(map));
     } else {
-      OSM.router.route("/" + OSM.formatHash(map));
+      OSM.router.route("/");
     }
   });