tango-app-api-audit 3.4.65 → 3.4.66

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-audit",
3
- "version": "3.4.65",
3
+ "version": "3.4.66",
4
4
  "description": "audit & audit metrics apis",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -4640,7 +4640,7 @@ export async function getDetectionAuditFile( req, res ) {
4640
4640
  let filterQuery ={};
4641
4641
  let filter=[];
4642
4642
  switch ( inputData.moduleType ) {
4643
- case 'mobile-detction':
4643
+ case 'mobile-detection':
4644
4644
  case 'uniform-detection':
4645
4645
  case 'open-time':
4646
4646
  case 'close-time':
@@ -4672,8 +4672,9 @@ export async function getDetectionAuditFile( req, res ) {
4672
4672
  fileDate: '$fileDate', storeId: '$storeId', zoneName: '$zoneName',
4673
4673
  };
4674
4674
  break;
4675
+ default:
4676
+ return res.sendError( 'Please give valid module type', 400 );
4675
4677
  }
4676
-
4677
4678
  const userQuery = [
4678
4679
  {
4679
4680
  $match: {
@@ -4869,7 +4870,7 @@ export async function getDetectionAuditFile( req, res ) {
4869
4870
  const bucketCDN = url.traxAuditInput;
4870
4871
  if ( folderPath?.length > 0 ) {
4871
4872
  switch ( inputData.moduleType ) {
4872
- case 'mobile-detction':
4873
+ case 'mobile-detection':
4873
4874
  case 'uniform-detection':
4874
4875
  case 'hygiene':
4875
4876
  for ( let i = 0; i < folderPath.length; i++ ) {
@@ -4921,6 +4922,8 @@ export async function getDetectionAuditFile( req, res ) {
4921
4922
  } );
4922
4923
  }
4923
4924
  break;
4925
+ default:
4926
+ return res.sendError( 'Please give valid module type', 400 );
4924
4927
  }
4925
4928
 
4926
4929
  if ( userDetails.length === 0 ) {
@@ -4971,6 +4974,8 @@ export async function getDetectionAuditFile( req, res ) {
4971
4974
  moduleType: inputData.moduleType,
4972
4975
  };
4973
4976
  break;
4977
+ default:
4978
+ return res.sendError( 'Please give valid module type', 400 );
4974
4979
  }
4975
4980
 
4976
4981
  const storeRecord = {
@@ -5404,7 +5409,7 @@ export async function reTrigger( req, res ) {
5404
5409
  queueName=getQueueName?.auditConfigs?.traxQueueName?.openClose;
5405
5410
  break;
5406
5411
  default:
5407
- return res.sendError( 'Please give valid module type' );
5412
+ return res.sendError( 'Please give valid module type', 400 );
5408
5413
  }
5409
5414
  if ( !getQueueName || [ null, '', undefined ].includes( queueName ) ) {
5410
5415
  return res.sendError( `The queueName ${queueName} does not create`, 400 );