graticule 0.2.3 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,3 +1,6 @@
1
+ 0.2.4 (2007-05-15)
2
+ * fixed address mapping for local search maps (Tom Taylor)
3
+
1
4
  0.2.3 (2007-04-27)
2
5
  * fixed Google for less precise queries
3
6
  * added User-Agent to coerce Google into returning UTF-8 (Jonathan Tron)
@@ -16,7 +16,7 @@ module Graticule #:nodoc:
16
16
 
17
17
  private
18
18
 
19
- def read_response(response)
19
+ def prepare_response(response)
20
20
  # add new line so YAML.load doesn't puke
21
21
  YAML.load(response + "\n")
22
22
  end
@@ -20,9 +20,9 @@ module Graticule #:nodoc:
20
20
  private
21
21
 
22
22
  def map_attributes(location)
23
- mapping = {:street => :address, :locality => :city, :region => :state, :postal_code => :zip}
23
+ mapping = {:street => :address, :locality => :city, :region => :state, :postal_code => :zip, :country => :country}
24
24
  mapping.keys.inject({}) do |result,attribute|
25
- result[mapping[attribute]] = location.attributes[attribute]
25
+ result[mapping[attribute]] = location.attributes[attribute] unless location.attributes[attribute].blank?
26
26
  result
27
27
  end
28
28
  end
@@ -2,7 +2,7 @@ module Graticule #:nodoc:
2
2
  module Version #:nodoc:
3
3
  MAJOR = 0
4
4
  MINOR = 2
5
- TINY = 3
5
+ TINY = 4
6
6
 
7
7
  STRING = [MAJOR, MINOR, TINY].join('.')
8
8
  end
metadata CHANGED
@@ -3,8 +3,8 @@ rubygems_version: 0.9.2
3
3
  specification_version: 1
4
4
  name: graticule
5
5
  version: !ruby/object:Gem::Version
6
- version: 0.2.3
7
- date: 2007-04-27 00:00:00 -04:00
6
+ version: 0.2.4
7
+ date: 2007-05-15 00:00:00 -04:00
8
8
  summary: API for using all the popular geocoding services.
9
9
  require_paths:
10
10
  - lib