@ventlio/tanstack-query 0.5.3 → 0.5.4

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.mjs CHANGED
@@ -352,7 +352,7 @@ async function makeRequest({ body = {}, method = HttpMethod.GET, path, isFormDat
352
352
  method,
353
353
  onUploadProgress,
354
354
  };
355
- if (Object.keys(body).length > 0) {
355
+ if (Object.keys(body).length > 0 || (isFormData && !isApp && [...body.keys()].length > 0)) {
356
356
  axiosRequestConfig.data = body;
357
357
  }
358
358
  // send request
@@ -19,7 +19,7 @@ async function makeRequest({ body = {}, method = HttpMethod.GET, path, isFormDat
19
19
  method,
20
20
  onUploadProgress,
21
21
  };
22
- if (Object.keys(body).length > 0) {
22
+ if (Object.keys(body).length > 0 || (isFormData && !isApp && [...body.keys()].length > 0)) {
23
23
  axiosRequestConfig.data = body;
24
24
  }
25
25
  // send request
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ventlio/tanstack-query",
3
- "version": "0.5.3",
3
+ "version": "0.5.4",
4
4
  "license": "MIT",
5
5
  "main": "dist/index.js",
6
6
  "contributors": [
@@ -37,7 +37,7 @@ export async function makeRequest<TResponse>({
37
37
  onUploadProgress,
38
38
  };
39
39
 
40
- if (Object.keys(body).length > 0) {
40
+ if (Object.keys(body).length > 0 || (isFormData && !isApp && [...body.keys()].length > 0)) {
41
41
  axiosRequestConfig.data = body;
42
42
  }
43
43