@defjs/core 0.0.0-test-0009 → 0.0.0-test-0010
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.js +2 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -285,9 +285,6 @@ async function fillRequestFromField(request, fieldOrFieldGroup, input) {
|
|
|
285
285
|
}
|
|
286
286
|
for (const [type, aliasName] of meta.alias) {
|
|
287
287
|
switch (type) {
|
|
288
|
-
case 1 /* Json */:
|
|
289
|
-
body = JSON.stringify(fieldValue);
|
|
290
|
-
break;
|
|
291
288
|
case 2 /* Query */: {
|
|
292
289
|
if (!aliasName) {
|
|
293
290
|
throwAliaNotSet();
|
|
@@ -316,6 +313,7 @@ async function fillRequestFromField(request, fieldOrFieldGroup, input) {
|
|
|
316
313
|
body = appendValue(new FormData, aliasName, fieldValue);
|
|
317
314
|
break;
|
|
318
315
|
}
|
|
316
|
+
case 1 /* Json */:
|
|
319
317
|
case 6 /* Body */:
|
|
320
318
|
body = fieldValue;
|
|
321
319
|
break;
|
|
@@ -379,7 +377,7 @@ async function fillRequestFromField(request, fieldOrFieldGroup, input) {
|
|
|
379
377
|
} else if (Array.from(formData.keys()).length > 0) {
|
|
380
378
|
request.body = formData;
|
|
381
379
|
} else if (Object.keys(json).length) {
|
|
382
|
-
request.body =
|
|
380
|
+
request.body = json;
|
|
383
381
|
}
|
|
384
382
|
return;
|
|
385
383
|
}
|