@lad-tech/nsc-toolkit 2.0.1 → 2.0.3

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/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
- ## [2.0.1](https://github.com/lad-tech/nsc-toolkit/compare/v2.0.0...v2.0.1) (2025-07-07)
1
+ ## [2.0.3](https://github.com/lad-tech/nsc-toolkit/compare/v2.0.2...v2.0.3) (2025-07-16)
2
2
 
3
3
 
4
4
  ### Bug Fixes
5
5
 
6
- * Fix off method ([#151](https://github.com/lad-tech/nsc-toolkit/issues/151)) ([a6eafb4](https://github.com/lad-tech/nsc-toolkit/commit/a6eafb4679f2846496afde639b52dca86b2afc97))
6
+ * error if func result empty ([#154](https://github.com/lad-tech/nsc-toolkit/issues/154)) ([2ae4a9d](https://github.com/lad-tech/nsc-toolkit/commit/2ae4a9de5657e79199f5e43e77efacff36265fca))
package/dist/Service.js CHANGED
@@ -133,7 +133,7 @@ class Service extends Root_1.Root {
133
133
  const span = tracer.startSpan(func.name, undefined, context);
134
134
  try {
135
135
  const result = func.apply(funcContext, arg);
136
- if (result.then) {
136
+ if (result === null || result === void 0 ? void 0 : result.then) {
137
137
  return result.then((result) => {
138
138
  this.finishSpan(span, undefined, tag);
139
139
  return result;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lad-tech/nsc-toolkit",
3
- "version": "2.0.1",
3
+ "version": "2.0.3",
4
4
  "description": "Toolkit for create microservices around NATS",
5
5
  "main": "dist/index.js",
6
6
  "types": "./dist/types/index.d.ts",