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

Revert "Merge pull request #508 from jezstephens/mapquest-version"

This reverts commit 4ba15c82, reversing
changes made to c740bbb7.

Conflicts:
	lib/geocoder/lookups/mapquest.rb
	test/services_test.rb
parent c557ba43
No related branches found
No related tags found
No related merge requests found
......@@ -15,8 +15,7 @@ module Geocoder::Lookup
def query_url(query)
domain = configuration[:open] ? "open" : "www"
version = configuration[:version] || 1
url = "#{protocol}://#{domain}.mapquestapi.com/geocoding/v#{version}/#{search_type(query)}?"
url = "#{protocol}://#{domain}.mapquestapi.com/geocoding/v1/#{search_type(query)}?"
url + url_query_string(query)
end
......
......@@ -14,12 +14,6 @@ class MapquestTest < GeocoderTestCase
assert_equal "http://www.mapquestapi.com/geocoding/v1/address?key=abc123&location=Bluffton%2C+SC", query.url
end
def test_url_for_version_2
Geocoder.configure(mapquest: {api_key: "abc123", version: 2})
query = Geocoder::Query.new("Bluffton, SC")
assert_equal "http://www.mapquestapi.com/geocoding/v2/address?key=abc123&location=Bluffton%2C+SC", query.url
end
def test_url_for_open_street_maps
Geocoder.configure(mapquest: {api_key: "abc123", open: true})
query = Geocoder::Query.new("Bluffton, SC")
......
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