From ee1d697fc212ca69a236b28ff6224f1cbcdd5940 Mon Sep 17 00:00:00 2001 From: Jed Schneider <jed.schneider@modeset.com> Date: Tue, 16 Oct 2012 16:28:58 -0400 Subject: [PATCH] reformatting address for mapquest result --- lib/geocoder/results/mapquest.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/geocoder/results/mapquest.rb b/lib/geocoder/results/mapquest.rb index 6c45305a..354d8e61 100644 --- a/lib/geocoder/results/mapquest.rb +++ b/lib/geocoder/results/mapquest.rb @@ -45,7 +45,7 @@ module Geocoder::Result end def address - "#{street}, #{city}, #{state}, #{postal_code}, #{country}" + [street, city, state, postal_code, country].reject{|s| s.length == 0 }.join(", ") end end end -- GitLab