dce-reactkit 3.7.36 → 3.7.37
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/cjs/index.js +10 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +10 -1
- package/dist/esm/index.js.map +1 -1
- package/package.json +1 -1
- package/src/helpers/visitServerEndpoint.tsx +13 -1
package/dist/esm/index.js
CHANGED
|
@@ -762,12 +762,21 @@ const visitServerEndpoint = (opts) => __awaiter(void 0, void 0, void 0, function
|
|
|
762
762
|
// Error
|
|
763
763
|
throw new ErrorWithCode(stubResponse.errorMessage, stubResponse.errorCode);
|
|
764
764
|
}
|
|
765
|
+
// Remove properties with undefined values
|
|
766
|
+
let params;
|
|
767
|
+
if (opts.params) {
|
|
768
|
+
params = Object.fromEntries(Object
|
|
769
|
+
.entries(opts.params)
|
|
770
|
+
.filter(([key, value]) => {
|
|
771
|
+
return value !== undefined;
|
|
772
|
+
}));
|
|
773
|
+
}
|
|
765
774
|
// Send the request
|
|
766
775
|
const sendRequest = yield getSendRequest();
|
|
767
776
|
const response = yield sendRequest({
|
|
768
777
|
path: opts.path,
|
|
769
778
|
method: (_c = opts.method) !== null && _c !== void 0 ? _c : 'GET',
|
|
770
|
-
params
|
|
779
|
+
params,
|
|
771
780
|
});
|
|
772
781
|
// Check for failure
|
|
773
782
|
if (!response || !response.body) {
|