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

Remove code that compensated for Google's ISO 8859-1/UTF-8 encoding bug (now fixed).

parent 66fabc8d
No related branches found
No related tags found
No related merge requests found
......@@ -209,15 +209,10 @@ module Geocoder
# Query Google for geographic information about the given phrase.
# Returns the XML response as a hash. This method is not intended for
# general use (prefer Geocoder.search).
#
# Google's XML document has incorrect encoding (says UTF-8 but is actually
# ISO 8859-1). We have to fix this or REXML won't parse it correctly.
# This may be fixed in the future; see the bug report at:
# http://code.google.com/p/gmaps-api-issues/issues/detail?id=233
#
def self.search(query)
if doc = _fetch_xml(query)
REXML::Document.new(doc.sub('UTF-8', 'ISO-8859-1'))
REXML::Document.new(doc)
end
end
......
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