chockstone 0.3.0 → 0.3.1
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.
- data/chockstone.gemspec +1 -1
- data/lib/chockstone/connection.rb +7 -1
- metadata +1 -1
data/chockstone.gemspec
CHANGED
@@ -147,7 +147,7 @@ module Chockstone
|
|
147
147
|
}
|
148
148
|
|
149
149
|
formatted_response.merge!({ :alert => alert }) unless alert[:name].nil? and alert[:type].nil?
|
150
|
-
formatted_response.merge!({ :data => data }) unless data.blank?
|
150
|
+
formatted_response.merge!({ :data => key_to_sym(data) }) unless data.blank?
|
151
151
|
|
152
152
|
formatted_response
|
153
153
|
|
@@ -187,6 +187,12 @@ module Chockstone
|
|
187
187
|
}
|
188
188
|
|
189
189
|
end
|
190
|
+
|
191
|
+
def key_to_sym hash
|
192
|
+
return hash unless hash.is_a?(Hash)
|
193
|
+
hash = hash.inject({}){|memo,(k,v)| memo[k.to_sym] = s_key_to_sym(v); memo}
|
194
|
+
hash
|
195
|
+
end
|
190
196
|
end
|
191
197
|
|
192
198
|
end
|