fastlane-plugin-huawei_appgallery_connect 1.0.5 → 1.0.6
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b6f398ea6efa63723dd321360132b68c1a120b47ef13ed83ad93af2d3c94cc4b
|
4
|
+
data.tar.gz: d6bf21ea4de080bd5484f4ee06bd26279be483c15b4308bf5b30a75c47e1f634
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6071a5b8ba6c6172b644c38fc90e910e3338172299d7df581d0367e579724e9bd875b6a4307c6a72f13688e67485b902e3a49852061bbe3b659a3eaceaa51dfe
|
7
|
+
data.tar.gz: 4448629f51054b2edabb54465f8f7da46e228a8d40efb881c384fa348b444770f993a932104f890070f1e937f486d12462ec78551b4c3fbff50fe1b38f5048e1
|
data/lib/fastlane/plugin/huawei_appgallery_connect/helper/huawei_appgallery_connect_helper.rb
CHANGED
@@ -31,7 +31,10 @@ module Fastlane
|
|
31
31
|
request["client_id"] = client_id
|
32
32
|
request["Authorization"] = "Bearer #{token}"
|
33
33
|
response = http.request(request)
|
34
|
-
|
34
|
+
if !response.kind_of? Net::HTTPSuccess
|
35
|
+
UI.user_error!("Cannot obtain app info, please check API Token / Permissions (status code: #{response.code})")
|
36
|
+
return false
|
37
|
+
end
|
35
38
|
result_json = JSON.parse(response.body)
|
36
39
|
|
37
40
|
if result_json['ret']['code'] == 0
|
@@ -57,7 +60,10 @@ module Fastlane
|
|
57
60
|
request.body = {privacyPolicy: privacy_policy_url}.to_json
|
58
61
|
|
59
62
|
response = http.request(request)
|
60
|
-
|
63
|
+
if !response.kind_of? Net::HTTPSuccess
|
64
|
+
UI.user_error!("Cannot update app info, please check API Token / Permissions (status code: #{response.code})")
|
65
|
+
return false
|
66
|
+
end
|
61
67
|
result_json = JSON.parse(response.body)
|
62
68
|
|
63
69
|
if result_json['ret']['code'] == 0
|
@@ -105,6 +111,10 @@ module Fastlane
|
|
105
111
|
request.set_form form_data, 'multipart/form-data'
|
106
112
|
|
107
113
|
result = http.request(request)
|
114
|
+
if !result.kind_of? Net::HTTPSuccess
|
115
|
+
UI.user_error!("Cannot upload app, please check API Token / Permissions (status code: #{result.code})")
|
116
|
+
return false
|
117
|
+
end
|
108
118
|
result_json = JSON.parse(result.body)
|
109
119
|
|
110
120
|
if result_json['result']['result_code'].to_i == 0
|
@@ -129,7 +139,10 @@ module Fastlane
|
|
129
139
|
|
130
140
|
request.body = data
|
131
141
|
response = http.request(request)
|
132
|
-
|
142
|
+
if !response.kind_of? Net::HTTPSuccess
|
143
|
+
UI.user_error!("Cannot save app info, please check API Token / Permissions (status code: #{response.code})")
|
144
|
+
return false
|
145
|
+
end
|
133
146
|
result_json = JSON.parse(response.body)
|
134
147
|
|
135
148
|
if result_json['ret']['code'] == 0
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fastlane-plugin-huawei_appgallery_connect
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shreejan Shrestha
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-05-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: pry
|