rads-db 0.1.80 → 0.1.82

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.
@@ -39,7 +39,9 @@ var _default = options => (schema, entity) => {
39
39
  const fetchOptions = {
40
40
  method: "POST",
41
41
  body: JSON.stringify(args),
42
- headers: {}
42
+ headers: {
43
+ "Content-Type": "application/json"
44
+ }
43
45
  };
44
46
  fetchOptions.headers = {
45
47
  ...fetchOptions.headers,
@@ -54,7 +56,9 @@ var _default = options => (schema, entity) => {
54
56
  body: JSON.stringify({
55
57
  data: item
56
58
  }),
57
- headers: {}
59
+ headers: {
60
+ "Content-Type": "application/json"
61
+ }
58
62
  };
59
63
  fetchOptions.headers = {
60
64
  ...fetchOptions.headers,
@@ -33,7 +33,7 @@ export default (options) => (schema, entity) => {
33
33
  const fetchOptions = {
34
34
  method: "POST",
35
35
  body: JSON.stringify(args),
36
- headers: {}
36
+ headers: { "Content-Type": "application/json" }
37
37
  };
38
38
  fetchOptions.headers = { ...fetchOptions.headers, ...opts.getHeaders(url, fetchOptions) };
39
39
  return await fetchInner(url, fetchOptions);
@@ -43,7 +43,7 @@ export default (options) => (schema, entity) => {
43
43
  const fetchOptions = {
44
44
  method: "PUT",
45
45
  body: JSON.stringify({ data: item }),
46
- headers: {}
46
+ headers: { "Content-Type": "application/json" }
47
47
  };
48
48
  fetchOptions.headers = { ...fetchOptions.headers, ...opts.getHeaders(url, fetchOptions) };
49
49
  return await fetchInner(url, fetchOptions);
@@ -18,6 +18,9 @@ var _default = options => {
18
18
  const body = options.useFormData ? getFormDataBody(args) : await getJsonBody(args);
19
19
  const response = await fetch(`${options.baseUrl}/uploadFile`, {
20
20
  method: "POST",
21
+ headers: {
22
+ "Content-Type": "application/json"
23
+ },
21
24
  body
22
25
  });
23
26
  return await response.json();
@@ -9,6 +9,7 @@ export default (options) => {
9
9
  const body = options.useFormData ? getFormDataBody(args) : await getJsonBody(args);
10
10
  const response = await fetch(`${options.baseUrl}/uploadFile`, {
11
11
  method: "POST",
12
+ headers: { "Content-Type": "application/json" },
12
13
  body
13
14
  });
14
15
  return await response.json();
package/package.json CHANGED
@@ -40,7 +40,7 @@
40
40
  "require": "./features/*.cjs"
41
41
  }
42
42
  },
43
- "version": "0.1.80",
43
+ "version": "0.1.82",
44
44
  "description": "Say goodbye to boilerplate code and hello to efficient and elegant syntax.",
45
45
  "keywords": [],
46
46
  "author": "",