@devite/shopware-client 1.7.1 → 1.7.3
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/dist/index.cjs +3 -3
- package/dist/index.mjs +3 -3
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -141,7 +141,7 @@ class ShopwareClient {
|
|
|
141
141
|
body: await this.parseBody(response)
|
|
142
142
|
});
|
|
143
143
|
}
|
|
144
|
-
})
|
|
144
|
+
}).catch(() => void 0)
|
|
145
145
|
);
|
|
146
146
|
}
|
|
147
147
|
async parseBody(response) {
|
|
@@ -316,7 +316,7 @@ function createRestEndpoint(client, resourceIdentifier, dataName) {
|
|
|
316
316
|
client,
|
|
317
317
|
HTTPRequestMethod.POST,
|
|
318
318
|
`/${resourceIdentifier}`,
|
|
319
|
-
|
|
319
|
+
responseDetails === "detail" ? 200 : 204,
|
|
320
320
|
`create ${dataName}`,
|
|
321
321
|
{ _response: responseDetails },
|
|
322
322
|
new JsonPayload(data)
|
|
@@ -344,7 +344,7 @@ function createRestEndpoint(client, resourceIdentifier, dataName) {
|
|
|
344
344
|
client,
|
|
345
345
|
HTTPRequestMethod.PATCH,
|
|
346
346
|
`/${resourceIdentifier}/${id}`,
|
|
347
|
-
200,
|
|
347
|
+
responseDetails === "detail" ? 200 : 204,
|
|
348
348
|
`update ${dataName} with id ${id}`,
|
|
349
349
|
{ _response: responseDetails },
|
|
350
350
|
new JsonPayload(data)
|
package/dist/index.mjs
CHANGED
|
@@ -139,7 +139,7 @@ class ShopwareClient {
|
|
|
139
139
|
body: await this.parseBody(response)
|
|
140
140
|
});
|
|
141
141
|
}
|
|
142
|
-
})
|
|
142
|
+
}).catch(() => void 0)
|
|
143
143
|
);
|
|
144
144
|
}
|
|
145
145
|
async parseBody(response) {
|
|
@@ -314,7 +314,7 @@ function createRestEndpoint(client, resourceIdentifier, dataName) {
|
|
|
314
314
|
client,
|
|
315
315
|
HTTPRequestMethod.POST,
|
|
316
316
|
`/${resourceIdentifier}`,
|
|
317
|
-
|
|
317
|
+
responseDetails === "detail" ? 200 : 204,
|
|
318
318
|
`create ${dataName}`,
|
|
319
319
|
{ _response: responseDetails },
|
|
320
320
|
new JsonPayload(data)
|
|
@@ -342,7 +342,7 @@ function createRestEndpoint(client, resourceIdentifier, dataName) {
|
|
|
342
342
|
client,
|
|
343
343
|
HTTPRequestMethod.PATCH,
|
|
344
344
|
`/${resourceIdentifier}/${id}`,
|
|
345
|
-
200,
|
|
345
|
+
responseDetails === "detail" ? 200 : 204,
|
|
346
346
|
`update ${dataName} with id ${id}`,
|
|
347
347
|
{ _response: responseDetails },
|
|
348
348
|
new JsonPayload(data)
|