gantt-task-react-powern 0.5.7 → 0.5.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.js CHANGED
@@ -3615,7 +3615,7 @@ function computeCriticalPath(taskID, taskMap) {
3615
3615
  taskMap[taskID].paths[0].task = dependents[j];
3616
3616
  taskMap[taskID].paths[0].parent = taskID;
3617
3617
  taskMap[taskID].paths[0].visited = false;
3618
- } else if (totalDuration > taskMap[taskID].paths[0].duration) {
3618
+ } else if (totalDuration > taskMap[taskID].paths[1].duration) {
3619
3619
  taskMap[taskID].paths[1].duration = totalDuration;
3620
3620
  taskMap[taskID].paths[1].task = dependents[j];
3621
3621
  taskMap[taskID].paths[1].parent = taskID;
@@ -3635,7 +3635,7 @@ function computeCriticalPath(taskID, taskMap) {
3635
3635
  taskMap[taskID].paths[0].task = dependents[j];
3636
3636
  taskMap[taskID].paths[0].parent = taskID;
3637
3637
  taskMap[taskID].paths[0].visited = false;
3638
- } else if (duration > taskMap[taskID].paths[0].duration) {
3638
+ } else if (duration > taskMap[taskID].paths[1].duration) {
3639
3639
  taskMap[taskID].paths[1].duration = duration;
3640
3640
  taskMap[taskID].paths[1].task = dependents[j];
3641
3641
  taskMap[taskID].paths[1].parent = taskID;