Open nealf opened 7 years ago
This is on the results list page (parks.html). If you go all the way back to the start and search again, it does get the current location
The latest pull request has this working on the parks.html and maps.html pages; however, I'm still considering a solution that doesn't involve a page reload. At the very least, I'd like to refactor those pages to use the deferred getLocation object. Therefore, I'm leaving open for now.
The location updates should work okay without prompting the user, because I am passing a get parameter to indicate whether or not the user has opted into using the geolocation API. If they've opted in, I think it is a reasonable choice to go ahead and update their location. The most recent commit reflects this approach.
On the maps page, I would still like to have a clear indication when the current location marker has updated and when updates have failed.
A page refresh should update the user's current location and update the display of closest parks