@lonca/trendyol 0.11.2 → 0.12.0
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 +9 -17
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +3 -18
- package/dist/index.js.map +1 -1
- package/dist/testing.cjs +1 -17
- package/dist/testing.cjs.map +1 -1
- package/dist/testing.js +2 -18
- package/dist/testing.js.map +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -2755,23 +2755,7 @@ function mapHttpError(status, body, retryAfterMs) {
|
|
|
2755
2755
|
}
|
|
2756
2756
|
function normalizeErrorIssues(body) {
|
|
2757
2757
|
const errors = extractErrorsArray(body);
|
|
2758
|
-
|
|
2759
|
-
const issues = [];
|
|
2760
|
-
for (const entry of errors) {
|
|
2761
|
-
if (typeof entry === "string") {
|
|
2762
|
-
issues.push({ message: entry });
|
|
2763
|
-
continue;
|
|
2764
|
-
}
|
|
2765
|
-
if (entry && typeof entry === "object") {
|
|
2766
|
-
const e = entry;
|
|
2767
|
-
if (typeof e.message !== "string") continue;
|
|
2768
|
-
const issue = { message: e.message };
|
|
2769
|
-
if (typeof e.field === "string") issue.field = e.field;
|
|
2770
|
-
if (typeof e.code === "string") issue.code = e.code;
|
|
2771
|
-
issues.push(issue);
|
|
2772
|
-
}
|
|
2773
|
-
}
|
|
2774
|
-
return issues;
|
|
2758
|
+
return errors ? core.normalizeIssueEntries(errors) : [];
|
|
2775
2759
|
}
|
|
2776
2760
|
function extractErrorsArray(body) {
|
|
2777
2761
|
if (!body || typeof body !== "object") return void 0;
|
|
@@ -2931,6 +2915,14 @@ var statusMap = {
|
|
|
2931
2915
|
};
|
|
2932
2916
|
var normalizeStatus = core.createStatusNormalizer(statusMap);
|
|
2933
2917
|
|
|
2918
|
+
Object.defineProperty(exports, "paginate", {
|
|
2919
|
+
enumerable: true,
|
|
2920
|
+
get: function () { return core.paginate; }
|
|
2921
|
+
});
|
|
2922
|
+
Object.defineProperty(exports, "paginateOffset", {
|
|
2923
|
+
enumerable: true,
|
|
2924
|
+
get: function () { return core.paginateOffset; }
|
|
2925
|
+
});
|
|
2934
2926
|
exports.BrandsResource = BrandsResource;
|
|
2935
2927
|
exports.CategoriesResource = CategoriesResource;
|
|
2936
2928
|
exports.ClaimsResource = ClaimsResource;
|