Skip to content
Snippets Groups Projects
Commit dde90a74 authored by Alex Reisner's avatar Alex Reisner
Browse files

Merge pull request #696 from alphasights/master

Get rid of extraneous "q=" in request query string.
parents d121d712 042da5ca
No related branches found
No related tags found
No related merge requests found
......@@ -9,7 +9,7 @@ module Geocoder::Lookup
end
def query_url(query)
"#{protocol}://api.opencagedata.com/geocode/v1/json?key=#{configuration.api_key}&q=#{url_query_string(query)}"
"#{protocol}://api.opencagedata.com/geocode/v1/json?key=#{configuration.api_key}&#{url_query_string(query)}"
end
def required_api_key_parts
......@@ -21,7 +21,7 @@ module Geocoder::Lookup
def results(query)
return [] unless doc = fetch_data(query)
# return doc["results"]
messages = doc['status']['message']
case doc['status']['code']
when 400 # Error with input
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment