@moostjs/event-wf 0.4.7 → 0.4.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.cjs CHANGED
@@ -72,6 +72,7 @@ class MoostWf {
72
72
  getControllerInstance: () => this.moost,
73
73
  callControllerMethod: () => undefined,
74
74
  logErrors: this.debug,
75
+ targetPath: '',
75
76
  })();
76
77
  }
77
78
  onInit(moost) {
@@ -110,17 +111,16 @@ class MoostWf {
110
111
  const schemaId = handler.path;
111
112
  const path = typeof schemaId === 'string' ? schemaId : typeof opts.method === 'string' ? opts.method : '';
112
113
  const targetPath = `${`${opts.prefix || ''}/${path}`.replace(/\/\/+/g, '/')}${path.endsWith('//') ? '/' : ''}`;
113
- if (!fn) {
114
- fn = moost.defineMoostEventHandler({
115
- contextType: CONTEXT_TYPE,
116
- loggerTitle: LOGGER_TITLE,
117
- getIterceptorHandler: opts.getIterceptorHandler,
118
- getControllerInstance: opts.getInstance,
119
- controllerMethod: opts.method,
120
- resolveArgs: opts.resolveArgs,
121
- manualUnscope: true,
122
- });
123
- }
114
+ fn = moost.defineMoostEventHandler({
115
+ contextType: CONTEXT_TYPE,
116
+ loggerTitle: LOGGER_TITLE,
117
+ getIterceptorHandler: opts.getIterceptorHandler,
118
+ getControllerInstance: opts.getInstance,
119
+ controllerMethod: opts.method,
120
+ resolveArgs: opts.resolveArgs,
121
+ manualUnscope: true,
122
+ targetPath,
123
+ });
124
124
  if (handler.type === 'WF_STEP') {
125
125
  this.wfApp.step(targetPath, {
126
126
  handler: fn,
package/dist/index.mjs CHANGED
@@ -71,6 +71,7 @@ class MoostWf {
71
71
  getControllerInstance: () => this.moost,
72
72
  callControllerMethod: () => undefined,
73
73
  logErrors: this.debug,
74
+ targetPath: '',
74
75
  })();
75
76
  }
76
77
  onInit(moost) {
@@ -109,17 +110,16 @@ class MoostWf {
109
110
  const schemaId = handler.path;
110
111
  const path = typeof schemaId === 'string' ? schemaId : typeof opts.method === 'string' ? opts.method : '';
111
112
  const targetPath = `${`${opts.prefix || ''}/${path}`.replace(/\/\/+/g, '/')}${path.endsWith('//') ? '/' : ''}`;
112
- if (!fn) {
113
- fn = defineMoostEventHandler({
114
- contextType: CONTEXT_TYPE,
115
- loggerTitle: LOGGER_TITLE,
116
- getIterceptorHandler: opts.getIterceptorHandler,
117
- getControllerInstance: opts.getInstance,
118
- controllerMethod: opts.method,
119
- resolveArgs: opts.resolveArgs,
120
- manualUnscope: true,
121
- });
122
- }
113
+ fn = defineMoostEventHandler({
114
+ contextType: CONTEXT_TYPE,
115
+ loggerTitle: LOGGER_TITLE,
116
+ getIterceptorHandler: opts.getIterceptorHandler,
117
+ getControllerInstance: opts.getInstance,
118
+ controllerMethod: opts.method,
119
+ resolveArgs: opts.resolveArgs,
120
+ manualUnscope: true,
121
+ targetPath,
122
+ });
123
123
  if (handler.type === 'WF_STEP') {
124
124
  this.wfApp.step(targetPath, {
125
125
  handler: fn,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moostjs/event-wf",
3
- "version": "0.4.7",
3
+ "version": "0.4.8",
4
4
  "description": "@moostjs/event-wf",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.mjs",
@@ -37,10 +37,10 @@
37
37
  },
38
38
  "peerDependencies": {},
39
39
  "dependencies": {
40
- "moost": "0.4.7",
41
- "wooks": "^0.5.5",
42
- "@wooksjs/event-core": "^0.5.5",
43
- "@wooksjs/event-wf": "^0.5.5",
40
+ "moost": "0.4.8",
41
+ "wooks": "^0.5.9",
42
+ "@wooksjs/event-core": "^0.5.9",
43
+ "@wooksjs/event-wf": "^0.5.9",
44
44
  "@prostojs/infact": "^0.2.3",
45
45
  "@prostojs/mate": "^0.3.2",
46
46
  "@prostojs/wf": "^0.0.18"