lib 2.0.0 → 2.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/lib.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d273649cb28a1780a92a58a3f2e5c91a06f28b00
|
4
|
+
data.tar.gz: 015a687683d986dc641ab88522777b324be2a923
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dd7609597dd4c8da4c18748600f105ebceca2bf31d90b4dd747524a96a8137c66773fac6e629a2286a5b0c0769164cab7eaf610a2c4a61b126375417ce470408
|
7
|
+
data.tar.gz: 6125797d996865ddd4f2f75cde6a5a45ac1f5e6d77f54687b45f275bf3821ff74a51f7db10cb4182b5706e980126af344a445aa9cbc70f64e863759330c13f5f
|
data/lib/lib.rb
CHANGED
@@ -159,7 +159,7 @@ module Lib
|
|
159
159
|
if contentType === 'application/json' then
|
160
160
|
response = response.to_s
|
161
161
|
begin
|
162
|
-
response = JSON.parse(response)
|
162
|
+
response = ('{['.include? response[0]) ? JSON.parse(response) : JSON.parse("[#{response}]")[0]
|
163
163
|
rescue
|
164
164
|
response = nil
|
165
165
|
end
|