edwardsamuel / google-maps-services-ruby

Ruby gem for Google Maps Web Service APIs
Apache License 2.0
91 stars 53 forks source link

Return full response for Directions API #6

Open SunnyKarma opened 8 years ago

SunnyKarma commented 8 years ago

return get('/maps/api/directions/json', params)[:routes]

At this moment, client.directions returns only [:routes] element of the JSON response from Google Directions API. But in some cases it needs to handle [:status] element or _[:available_travelmodes]. So it could be better if it just returns full response or we can specify it.