biz-a-cli 2.3.77 → 2.3.78

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,12 +39,9 @@ export async function save(payload) {
39
39
  initial_state_code: workflowJson.initialStateCode || "",
40
40
  status: "DRAFT",
41
41
  definition_json: minifiedJsonString,
42
+ created_by: Number.isFinite(Number(userId)) ? Number(userId) : null,
42
43
  };
43
44
 
44
- if (!id && userId) {
45
- dbModel.created_by = parseInt(userId, 10) || null;
46
- }
47
-
48
45
  const result = await dbSave(
49
46
  {
50
47
  SYS$BPM_WORKFLOW_DEF: dbModel,
@@ -120,7 +117,7 @@ export async function publish(payload) {
120
117
  description: workflowJson.description || "",
121
118
  initial_state_code: workflowJson.initialStateCode,
122
119
  status: "PUBLISHED",
123
- published_by: parseInt(userId, 10) || null,
120
+ published_by: Number.isFinite(Number(userId)) ? Number(userId) : null,
124
121
  definition_json: JSON.stringify(workflowJson),
125
122
  };
126
123
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "biz-a-cli",
3
- "version": "2.3.77",
3
+ "version": "2.3.78",
4
4
  "description": "",
5
5
  "main": "bin/index.js",
6
6
  "type": "module",