@twin.org/api-models 0.0.1-next.34 → 0.0.1-next.36

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.
@@ -65,10 +65,7 @@ class HttpErrorHelper {
65
65
  else if (flattened.some(e => core.BaseError.isErrorName(e, core.UnprocessableError.CLASS_NAME))) {
66
66
  httpStatusCode = web.HttpStatusCode.unprocessableEntity;
67
67
  }
68
- const returnError = error.toJsonObject();
69
- if (!includeStack) {
70
- delete returnError.stack;
71
- }
68
+ const returnError = error.toJsonObject(includeStack);
72
69
  return {
73
70
  error: returnError,
74
71
  httpStatusCode
@@ -63,10 +63,7 @@ class HttpErrorHelper {
63
63
  else if (flattened.some(e => BaseError.isErrorName(e, UnprocessableError.CLASS_NAME))) {
64
64
  httpStatusCode = HttpStatusCode.unprocessableEntity;
65
65
  }
66
- const returnError = error.toJsonObject();
67
- if (!includeStack) {
68
- delete returnError.stack;
69
- }
66
+ const returnError = error.toJsonObject(includeStack);
70
67
  return {
71
68
  error: returnError,
72
69
  httpStatusCode
package/docs/changelog.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # @twin.org/api-models - Changelog
2
2
 
3
+ ## [0.0.1-next.36](https://github.com/twinfoundation/api/compare/api-models-v0.0.1-next.35...api-models-v0.0.1-next.36) (2025-06-17)
4
+
5
+
6
+ ### Features
7
+
8
+ * use new includeStackTrace flag for toJsonObject ([6452b15](https://github.com/twinfoundation/api/commit/6452b153af786eee14b21152420f8a2578b70593))
9
+
10
+ ## [0.0.1-next.35](https://github.com/twinfoundation/api/compare/api-models-v0.0.1-next.34...api-models-v0.0.1-next.35) (2025-06-11)
11
+
12
+
13
+ ### Features
14
+
15
+ * update dependencies ([1171dc4](https://github.com/twinfoundation/api/commit/1171dc416a9481737f6a640e3cf30145768f37e9))
16
+
3
17
  ## [0.0.1-next.34](https://github.com/twinfoundation/api/compare/api-models-v0.0.1-next.33...api-models-v0.0.1-next.34) (2025-05-27)
4
18
 
5
19
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@twin.org/api-models",
3
- "version": "0.0.1-next.34",
3
+ "version": "0.0.1-next.36",
4
4
  "description": "Contains models and classes for use with APIs",
5
5
  "repository": {
6
6
  "type": "git",