Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/pull/5088'
Browse files Browse the repository at this point in the history
  • Loading branch information
tomhughes committed Aug 16, 2024
2 parents 9e807ae + 80c43f5 commit 9b2db63
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions app/assets/javascripts/index/directions.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,12 +75,8 @@ OSM.Directions = function (map) {

$(".directions_form .btn-close").on("click", function (e) {
e.preventDefault();
var route_from = endpoints[0].value;
if (route_from) {
OSM.router.route("/?query=" + encodeURIComponent(route_from) + OSM.formatHash(map));
} else {
OSM.router.route("/" + OSM.formatHash(map));
}
$(".search_form input[name='query']").val(endpoints[0].value);
OSM.router.route("/" + OSM.formatHash(map));
});

function formatDistance(m) {
Expand Down

0 comments on commit 9b2db63

Please sign in to comment.