yehezkielbs-contacts 1.2.12 → 1.2.13
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/contacts/aol.rb +11 -5
- metadata +4 -4
data/lib/contacts/aol.rb
CHANGED
@@ -134,14 +134,20 @@ class Contacts
|
|
134
134
|
end
|
135
135
|
end
|
136
136
|
private
|
137
|
-
|
137
|
+
|
138
138
|
def parse(data, options={})
|
139
|
-
|
140
|
-
|
141
|
-
|
139
|
+
parsed = []
|
140
|
+
data.split("\n").each do |line|
|
141
|
+
begin
|
142
|
+
parsed << FasterCSV.parse_line(line)
|
143
|
+
rescue
|
144
|
+
end
|
145
|
+
end
|
146
|
+
col_names = parsed.shift
|
147
|
+
@contacts = parsed.map do |person|
|
142
148
|
["#{person[0]} #{person[1]}", person[4]] if person[4] && !person[4].empty?
|
143
149
|
end.compact
|
144
|
-
end
|
150
|
+
end
|
145
151
|
|
146
152
|
def h_to_query_string(hash)
|
147
153
|
u = ERB::Util.method(:u)
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yehezkielbs-contacts
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 5
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 1
|
8
8
|
- 2
|
9
|
-
-
|
10
|
-
version: 1.2.
|
9
|
+
- 13
|
10
|
+
version: 1.2.13
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Lucas Carlson
|
@@ -19,7 +19,7 @@ autorequire:
|
|
19
19
|
bindir: bin
|
20
20
|
cert_chain: []
|
21
21
|
|
22
|
-
date: 2012-04-
|
22
|
+
date: 2012-04-23 00:00:00 Z
|
23
23
|
dependencies:
|
24
24
|
- !ruby/object:Gem::Dependency
|
25
25
|
name: json
|