Skip to content

Conversation

@SBillion
Copy link

Don't make types required when using rankby='distance' if type is present.
Use all builtin to check multiple variable to None
Modify documentaiton on nearbysearch method.

Don't make types required when using rankby='distance' if type is present.
Use all builtin to check multiple variable to None
Modify documentaiton on nearbysearch method.
@danielsp3000
Copy link

There is a bug with this modification.
Try this

lat_lng = {'lat': 45.522217, 'lng': 9.214968}
query_result = google_places.nearby_search(
        lat_lng=lat_lng, radius=30, rankby='distance', types=[types.TYPE_RESTAURANT])

this returns only restaurants, while if we use

`lat_lng = {'lat': 45.522217, 'lng': 9.214968}
query_result = google_places.nearby_search(
        lat_lng=lat_lng, radius=30, rankby='distance', **type**=[types.TYPE_RESTAURANT])`

it returns also a clothing store.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants