qbo_api 1.5.3 → 1.5.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/example/app.rb +1 -1
- data/lib/qbo_api/raise_http_exception.rb +7 -6
- data/lib/qbo_api/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: e69a4a5edfc29a720f08c19a4a5181b5e7e35abf
|
4
|
+
data.tar.gz: 4b93a507c7ed1e54e1eee82dcff069793488da98
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bccdcddabe001203604d4871a158a2bd3fdd406f1e333f2a265862e7673d8fc84e23b42f7be56fe5f9852d68a7e2fcf2caca40df705ef24c4999d8806c29332d
|
7
|
+
data.tar.gz: 559263fa7322e121f69e85995e0304f11a5a43e025a2bddb9d7ae8f6c6d36014661109a8d7aceccade0ae3250810ab9bc142a6cb8ef451f158ed87b19affef9e
|
data/example/app.rb
CHANGED
@@ -52,13 +52,14 @@ module FaradayMiddleware
|
|
52
52
|
|
53
53
|
def parse_json(body)
|
54
54
|
res = ::JSON.parse(body)
|
55
|
-
|
56
|
-
|
55
|
+
fault = res['Fault'] || res['fault']
|
56
|
+
errors = fault['Error'] || fault['error']
|
57
|
+
errors.collect do |error|
|
57
58
|
{
|
58
|
-
fault_type:
|
59
|
-
error_code:
|
60
|
-
error_message:
|
61
|
-
error_detail:
|
59
|
+
fault_type: fault['type'],
|
60
|
+
error_code: error['code'],
|
61
|
+
error_message: error['Message'] || error['message'],
|
62
|
+
error_detail: error['Detail'] || error['detail']
|
62
63
|
}
|
63
64
|
end
|
64
65
|
end
|
data/lib/qbo_api/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: qbo_api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Christian Pelczarski
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-12-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|