beta-glozic-workflow 1.32.0 → 1.36.0

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.
Files changed (2) hide show
  1. package/dist/index.js +6 -4
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -89,9 +89,10 @@ class Designer extends _react.Component {
89
89
  if (action.configuration && action.configuration.actionID === targetActionID) {
90
90
  // Update branches array when actionID matches
91
91
  var tempBranch = action.branches;
92
- if (tempBranch.length > newBranches.length) {
93
- tempBranch = tempBranch.slice(0, newBranches.length);
94
- } else {
92
+ if (tempBranch.length >= newBranches.length) {
93
+ tempBranch = tempBranch.filter(branch => newBranches.some(newBranch => newBranch.label === branch.name));
94
+ }
95
+ if (tempBranch.length <= newBranches.length) {
95
96
  newBranches.forEach((ele, index) => {
96
97
  if (!tempBranch[index]) {
97
98
  tempBranch.push({
@@ -1991,7 +1992,8 @@ class Designer extends _react.Component {
1991
1992
  let endBranchId = "node-botbranch_".concat(i, "-").concat(self.nodes[node].count);
1992
1993
  newData[i] = [];
1993
1994
  let curBranch = Object.assign({}, this.nodes[node].branches[i], {
1994
- actions: []
1995
+ actions: [],
1996
+ name: "branch".concat(i)
1995
1997
  });
1996
1998
  while (cNode !== endBranchId) {
1997
1999
  //console.log('ele in branch ', cNode, this.nodes[cNode])
package/package.json CHANGED
@@ -7,7 +7,7 @@
7
7
  "components",
8
8
  "ui"
9
9
  ],
10
- "version": "1.32.0",
10
+ "version": "1.36.0",
11
11
  "private": false,
12
12
  "main": "dist/index.js",
13
13
  "module": "dist/index.js",