@aeriajs/common 0.0.102 → 0.0.104
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/freshItem.js +1 -1
- package/dist/freshItem.mjs +1 -1
- package/dist/http.js +1 -1
- package/dist/http.mjs +1 -1
- package/package.json +1 -1
package/dist/freshItem.js
CHANGED
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.freshItem = void 0;
|
|
4
4
|
const freshProperties = (properties) => Object.entries(properties).reduce((a, [key, property]) => {
|
|
5
5
|
const value = (() => {
|
|
6
|
-
if ('$ref' in property) {
|
|
6
|
+
if ('$ref' in property && property.inline) {
|
|
7
7
|
return {};
|
|
8
8
|
}
|
|
9
9
|
if ('properties' in property) {
|
package/dist/freshItem.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const freshProperties = (properties) => Object.entries(properties).reduce((a, [key, property]) => {
|
|
3
3
|
const value = (() => {
|
|
4
|
-
if ("$ref" in property) {
|
|
4
|
+
if ("$ref" in property && property.inline) {
|
|
5
5
|
return {};
|
|
6
6
|
}
|
|
7
7
|
if ("properties" in property) {
|
package/dist/http.js
CHANGED
|
@@ -13,7 +13,7 @@ const defaultRequestTransformer = async (url, payload, params) => {
|
|
|
13
13
|
else {
|
|
14
14
|
request.params.body = params.headers?.['content-type']?.startsWith('application/json')
|
|
15
15
|
? JSON.stringify(payload)
|
|
16
|
-
:
|
|
16
|
+
: payload;
|
|
17
17
|
}
|
|
18
18
|
}
|
|
19
19
|
return request;
|
package/dist/http.mjs
CHANGED
|
@@ -8,7 +8,7 @@ export const defaultRequestTransformer = async (url, payload, params) => {
|
|
|
8
8
|
if (params.method === "GET" || params.method === "HEAD") {
|
|
9
9
|
request2.url += `?${new URLSearchParams(payload)}`;
|
|
10
10
|
} else {
|
|
11
|
-
request2.params.body = params.headers?.["content-type"]?.startsWith("application/json") ? JSON.stringify(payload) :
|
|
11
|
+
request2.params.body = params.headers?.["content-type"]?.startsWith("application/json") ? JSON.stringify(payload) : payload;
|
|
12
12
|
}
|
|
13
13
|
}
|
|
14
14
|
return request2;
|