-
Notifications
You must be signed in to change notification settings - Fork 334
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
JSONP broken #321
Comments
Created PR #322 that should fix this. |
So, hacking around a bit with this code and the PR this last day or two. The PR does stop the error, but the search results produce an "undefined" result in the search box. I've tested this by changing the source code on the example online as well as my personal project. If it's any help, this is the request URL: https://nominatim.openstreetmap.org/search?format=json&q=London&json_callback=L.Control.Search.callJsonp And this is the response: L.Control.Search.callJsonp([{
"place_id": 344385499,
"licence": "Data © OpenStreetMap contributors, ODbL 1.0. https://osm.org/copyright",
"osm_type": "relation",
"osm_id": 65606,
"boundingbox": ["51.2867601", "51.6918741", "-0.5103751", "0.3340155"],
"lat": "51.5073359",
"lon": "-0.12765",
"display_name": "London, Greater London, England, United Kingdom",
"class": "place",
"type": "city",
"importance": 0.9407827616237295,
"icon": "https://nominatim.openstreetmap.org/ui/mapicons/poi_place_city.p.20.png"
}]) |
Hello.
I query OSM Nominatim API via JSONP callback. Few months ago it stopped working -- whenever I try to search something, the following error is thrown:
After some investigation it turns out that recent versions call
_retrieveData
directly instead of usingthis._retrieveData.call(...)
, as it was before. So instead of 2 arguments (inputText and callback) the function is called with three, soinputText = this
andcallback = inputText
.The text was updated successfully, but these errors were encountered: