tango-app-api-trax 3.4.0-flag-0 → 3.4.0-flag-1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tango-app-api-trax",
3
- "version": "3.4.0-flag-0",
3
+ "version": "3.4.0-flag-1",
4
4
  "description": "Trax",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -2890,9 +2890,9 @@ export const flagComparisonCardsV2 = async ( req, res ) => {
2890
2890
  detectionComparisonFlag: { comparisonData: 0, ComparisonFlag: false },
2891
2891
  };
2892
2892
 
2893
- let rangeOneTotalFlag = rangeOneData[0].totalFlag + rangeOneDetectionCount;
2894
- let rangeTwoTotalFlag = rangeTwoData[0].totalFlag + rangeTwoDetectionCount;
2895
2893
  if ( rangeOneData.length && rangeTwoData.length ) {
2894
+ let rangeOneTotalFlag = rangeOneData[0].totalFlag + rangeOneDetectionCount || 0;
2895
+ let rangeTwoTotalFlag = rangeTwoData[0].totalFlag + rangeTwoDetectionCount || 0;
2896
2896
  flagComparisonCards.totalComparisonFlag = calculateComparison( rangeOneTotalFlag, rangeTwoTotalFlag );
2897
2897
  flagComparisonCards.questionComparisonFlag = calculateComparison( rangeOneData[0].questionFlag, rangeTwoData[0].questionFlag );
2898
2898
  flagComparisonCards.delayInSubmissionComparisonFlag = calculateComparison( rangeOneData[0].delayInSubmission, rangeTwoData[0].delayInSubmission );