(function (global) {
  'use strict';
  var $ = global.jQuery;
  var $geoLocate = $('.geo-locate');
  var $geoLocateDenied = $('.geo-locate--denied');
  var $geoLocateError = $('.geo-locate--error');
  var $geoLocateLocate = $('.geo-locate--locate');
  var $geoLocateSearching = $('.geo-locate--searching');
  var window = global;

  function success(position) {
    var latitude = position.coords.latitude;
    var longitude = position.coords.longitude;

    if (latitude && longitude) {
      var locationDescription = 'your location';
      var location = './results?location=' + encodeURIComponent(locationDescription) + '&latitude=' + latitude + '&longitude=' + longitude;
      // load the results page
      window.location = location;
    } else {
      error();
    }
  }

  function error(e) {
    switch(e.code) {
      case e.PERMISSION_DENIED:
        $geoLocate.hide();
        $geoLocateDenied.show();
        break;
      case e.POSITION_UNAVAILABLE:
        $geoLocateError.show();
        break;
      case e.TIMEOUT:
        $geoLocateError.show();
        break;
    }
    $geoLocateSearching.hide();
  }

  if (navigator.geolocation) {
    $geoLocate.show();

    $geoLocateLocate.on('click', function() {
      $geoLocateError.hide();
      navigator.geolocation.getCurrentPosition(success, error);
      $geoLocateSearching.show();
    });
  }
})(window);

@@ -1215,16 +1215,17 @@
 unction(
+e
 ) %7B%0A    
@@ -1344,24 +1344,50 @@
 ing.show();%0A
+      e.preventDefault();%0A
     %7D);%0A  %7D%0A

Stop page repositioning after using my location