@ventlio/tanstack-query 0.2.29 → 0.2.31

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
@@ -139,10 +139,12 @@ async function makeRequest({ body, method = HttpMethod.GET, path, isFormData, he
139
139
  // configure body
140
140
  body = isFormData ? buildFormData(body) : body;
141
141
  // configure request header
142
- console.log({ isFormData, body });
143
142
  if (!isFormData) {
144
143
  headers['Content-Type'] = ContentType.APPLICATION_JSON;
145
144
  }
145
+ else {
146
+ delete headers['Content-Type'];
147
+ }
146
148
  try {
147
149
  const axios = axiosInstance({ baseURL, headers, timeout });
148
150
  // send request
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -9,10 +9,12 @@ async function makeRequest({ body, method = request_enum.HttpMethod.GET, path, i
9
9
  // configure body
10
10
  body = isFormData ? buildFormData.buildFormData(body) : body;
11
11
  // configure request header
12
- console.log({ isFormData, body });
13
12
  if (!isFormData) {
14
13
  headers['Content-Type'] = request_enum.ContentType.APPLICATION_JSON;
15
14
  }
15
+ else {
16
+ delete headers['Content-Type'];
17
+ }
16
18
  try {
17
19
  const axios = axiosInstance.axiosInstance({ baseURL, headers, timeout });
18
20
  // send request
@@ -1 +1 @@
1
- {"version":3,"file":"make-request.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"make-request.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ventlio/tanstack-query",
3
- "version": "0.2.29",
3
+ "version": "0.2.31",
4
4
  "license": "MIT",
5
5
  "main": "dist/index.js",
6
6
  "contributors": [
@@ -18,11 +18,10 @@ export async function makeRequest<TResponse>({
18
18
  body = isFormData ? buildFormData(body as Record<string, any>) : body;
19
19
 
20
20
  // configure request header
21
-
22
- console.log({ isFormData, body });
23
-
24
21
  if (!isFormData) {
25
22
  headers['Content-Type'] = ContentType.APPLICATION_JSON;
23
+ } else {
24
+ delete headers['Content-Type'];
26
25
  }
27
26
 
28
27
  try {