godprotocol 2.2.47 → 2.2.49
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.
package/package.json
CHANGED
|
@@ -137,7 +137,7 @@ class Services {
|
|
|
137
137
|
|
|
138
138
|
if (conf.ok === false) return null;
|
|
139
139
|
|
|
140
|
-
let response = await fetch(conf
|
|
140
|
+
let response = await fetch(conf?.data?.url, {
|
|
141
141
|
method: "POST",
|
|
142
142
|
headers: {
|
|
143
143
|
"Content-Type": "application/json",
|
|
@@ -145,7 +145,7 @@ class Services {
|
|
|
145
145
|
"x-platform": req.headers["x-platform"],
|
|
146
146
|
"is-webhook": true,
|
|
147
147
|
authorization: req.headers["authorization"],
|
|
148
|
-
"x-api-version": conf
|
|
148
|
+
"x-api-version": conf?.data?.api_version || "v1",
|
|
149
149
|
},
|
|
150
150
|
body: JSON.stringify({
|
|
151
151
|
body: req.body,
|
|
@@ -178,7 +178,7 @@ class Services {
|
|
|
178
178
|
|
|
179
179
|
if (conf.ok === false) return null;
|
|
180
180
|
|
|
181
|
-
let response = await fetch(conf
|
|
181
|
+
let response = await fetch(conf?.data?.url, {
|
|
182
182
|
method: "POST",
|
|
183
183
|
headers: {
|
|
184
184
|
"Content-Type": "application/json",
|
|
@@ -186,7 +186,7 @@ class Services {
|
|
|
186
186
|
"x-platform": req.headers["x-platform"],
|
|
187
187
|
"is-webhook": true,
|
|
188
188
|
authorization: req.headers["authorization"],
|
|
189
|
-
"x-api-version": conf
|
|
189
|
+
"x-api-version": conf?.data?.api_version || "v1",
|
|
190
190
|
},
|
|
191
191
|
body: JSON.stringify({
|
|
192
192
|
response: result,
|