ozon-logistics 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ozon-logistics/api_request.rb +10 -5
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2168d1b02d6acacda56cffa233c5812ee1920b658eaa549a850ac26e491c9553
|
4
|
+
data.tar.gz: 9d72536c7ab2b4d7513a7945265a067797ad79a922a69846117698a0f34eea0d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 230ec71e16c34f7e8ff6a3c5b7f62375d6f464bf3539fa7692964a8d2b99a3b157f163987491b9bf557b74841446f7a3cd0d7778851e107c1144f6b4d32900cc
|
7
|
+
data.tar.gz: 2d39f2408ba2c5c4c1f309f4c279c5cb271fb34adfbc213ec5d6a8bf04302737b0cbdea7ebed29e668343236c8503c6ceaa309eac6fa746bfc3f30656e1d4d90
|
@@ -17,8 +17,9 @@ module OzonLogistics
|
|
17
17
|
if e.response[:status] == 401 && first_time
|
18
18
|
OzonLogistics::Request.access_token = OzonLogistics.generate_access_token.try(:dig, "access_token")
|
19
19
|
self.post(params: params, headers: headers, body: body, first_time: false)
|
20
|
+
else
|
21
|
+
handle_error(e)
|
20
22
|
end
|
21
|
-
handle_error(e)
|
22
23
|
end
|
23
24
|
end
|
24
25
|
|
@@ -35,8 +36,9 @@ module OzonLogistics
|
|
35
36
|
if e.response[:status] == 401 && first_time
|
36
37
|
OzonLogistics::Request.access_token = OzonLogistics.generate_access_token.try(:dig, "access_token")
|
37
38
|
self.patch(params: params, headers: headers, body: body, first_time: false)
|
39
|
+
else
|
40
|
+
handle_error(e)
|
38
41
|
end
|
39
|
-
handle_error(e)
|
40
42
|
end
|
41
43
|
end
|
42
44
|
|
@@ -52,8 +54,9 @@ module OzonLogistics
|
|
52
54
|
if e.response[:status] == 401 && first_time
|
53
55
|
OzonLogistics::Request.access_token = OzonLogistics.generate_access_token.try(:dig, "access_token")
|
54
56
|
self.put(params: params, headers: headers, body: body, first_time: false)
|
57
|
+
else
|
58
|
+
handle_error(e)
|
55
59
|
end
|
56
|
-
handle_error(e)
|
57
60
|
end
|
58
61
|
end
|
59
62
|
|
@@ -69,8 +72,9 @@ module OzonLogistics
|
|
69
72
|
if e.response[:status] == 401 && first_time
|
70
73
|
OzonLogistics::Request.access_token = OzonLogistics.generate_access_token.try(:dig, "access_token")
|
71
74
|
self.get(params: params, headers: headers, first_time: false)
|
75
|
+
else
|
76
|
+
handle_error(e)
|
72
77
|
end
|
73
|
-
handle_error(e)
|
74
78
|
end
|
75
79
|
end
|
76
80
|
|
@@ -86,8 +90,9 @@ module OzonLogistics
|
|
86
90
|
if e.response[:status] == 401 && first_time
|
87
91
|
OzonLogistics::Request.access_token = OzonLogistics.generate_access_token.try(:dig, "access_token")
|
88
92
|
self.delete(params: params, headers: headers, first_time: false)
|
93
|
+
else
|
94
|
+
handle_error(e)
|
89
95
|
end
|
90
|
-
handle_error(e)
|
91
96
|
end
|
92
97
|
end
|
93
98
|
|