how to use Google Maps Places provider: ->withData(...)?
wivaku opened this issue · 1 comments
wivaku commented
General Information
GeocoderLaravel Version: 4.3.2
Laravel Version: 7.15.0
PHP Version: 7.4.7
Operating System and Version: macOS
Issue Description
Google Maps Places states it expects additional parameter (key, name, type)
https://geocoder-php.org/docs/providers/googlemapsplaces/
$results = $provider
->reverseQuery(ReverseQuery::fromCoordinates(-33.892674, 151.200727)
->withData('type', 'bar'));
How to use in Laravel?
Steps to Replicate
$result = app('geocoder')
->using('google_maps_places')
->reverseQuery(\Geocoder\Query\ReverseQuery::fromCoordinates(-33.892674, 151.200727))
->withData('type', 'bar')
;
// error: One of `type`, `keyword`, `name` is required to be set in the Query data for Reverse Geocoding
wivaku commented
never mind