geomash 0.3.4 → 0.3.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/geomash/parser.rb +2 -1
- data/lib/geomash/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 92cf0c994109a517cd8243c00a52a886c2b1ea14
|
|
4
|
+
data.tar.gz: 3d868abd6b3334950fa9c69a00aa452497ba60cc
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 22cddf085958b18cfb4ded544255edad4dd2db3e5ef549a43e43307b128958173e23ff6e50be6dc2116c4c38c3ec03f6c7e7c203c907a260bd28d23dfd483e46
|
|
7
|
+
data.tar.gz: 6c86d48511dc735ea4d0b3079df8bd0d7ccbba5433bc3a2869eaebf2ea19ac971ee6af36c00fa066e6bfdf8ef140a27d3b3caca7953da3fefc99b911e49c3bd4
|
data/lib/geomash/parser.rb
CHANGED
|
@@ -230,8 +230,9 @@ module Geomash
|
|
|
230
230
|
|
|
231
231
|
#Check if only a partial match. To avoid errors, strip out the first part and try again...
|
|
232
232
|
#Need better way to check for street endings. See: http://pe.usps.gov/text/pub28/28apc_002.htm
|
|
233
|
+
#Fixme: This breaks Washington DC (Airport)
|
|
233
234
|
if google_api_result.present?
|
|
234
|
-
if google_api_result.first.data['partial_match'] && term.split(',').length > 1 && !term.downcase.include?('street') && !term.downcase.include?('st.') && !term.downcase.include?('avenue') && !term.downcase.include?('ave.') && !term.downcase.include?('court') && !term.downcase.include?('dr.')
|
|
235
|
+
if google_api_result.first.data['partial_match'] && term.split(',').length > 1 && !term.downcase.include?('street') && !term.downcase.include?('st.') && !term.downcase.include?('avenue') && !term.downcase.include?('ave.') && !term.downcase.include?('court') && !term.downcase.include?('dr.') && !term.downcase.include?('airport') && !term.downcase.include?('building')
|
|
235
236
|
term = term.split(',')[1..term.split(',').length-1].join(',').strip
|
|
236
237
|
google_api_result = Geocoder.search(term)
|
|
237
238
|
end
|
data/lib/geomash/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: geomash
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.3.
|
|
4
|
+
version: 0.3.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Boston Public Library
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2016-06-
|
|
11
|
+
date: 2016-06-02 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activesupport
|