@playcademy/sdk 0.2.7 → 0.2.8

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 CHANGED
@@ -1829,6 +1829,9 @@ function prepareRequestBody(body, headers) {
1829
1829
  return body;
1830
1830
  }
1831
1831
  if (body !== undefined && body !== null) {
1832
+ if (headers["Content-Type"]) {
1833
+ return typeof body === "string" ? body : JSON.stringify(body);
1834
+ }
1832
1835
  headers["Content-Type"] = "application/json";
1833
1836
  return JSON.stringify(body);
1834
1837
  }
package/dist/internal.js CHANGED
@@ -1953,6 +1953,9 @@ function prepareRequestBody(body, headers) {
1953
1953
  return body;
1954
1954
  }
1955
1955
  if (body !== undefined && body !== null) {
1956
+ if (headers["Content-Type"]) {
1957
+ return typeof body === "string" ? body : JSON.stringify(body);
1958
+ }
1956
1959
  headers["Content-Type"] = "application/json";
1957
1960
  return JSON.stringify(body);
1958
1961
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@playcademy/sdk",
3
- "version": "0.2.7",
3
+ "version": "0.2.8",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {
@@ -49,7 +49,7 @@
49
49
  "@playcademy/timeback": "0.0.1",
50
50
  "@playcademy/utils": "0.0.1",
51
51
  "@types/bun": "latest",
52
- "playcademy": "0.15.6",
52
+ "playcademy": "0.16.0",
53
53
  "rollup": "^4.50.2",
54
54
  "rollup-plugin-dts": "^6.2.3",
55
55
  "typescript": "^5.7.2"