sigo-package 1.1.39 → 1.1.41

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.
@@ -452,8 +452,12 @@ function convertDates(input) {
452
452
  }
453
453
  }
454
454
  function isValidDate(dateString) {
455
- var parsedDate = Date.parse(dateString);
456
- return !isNaN(parsedDate);
455
+ var dateRegex = /^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(?:\.\d{3})?Z?)?$/;
456
+ if (!dateRegex.test(dateString)) {
457
+ return false;
458
+ }
459
+ var parsedDate = new Date(dateString);
460
+ return !isNaN(parsedDate.getTime());
457
461
  }
458
462
 
459
463
  var Position;
@@ -599,6 +603,7 @@ function isValidPartialEntity(payload, entity, exception) {
599
603
  for (var _iterator = _createForOfIteratorHelperLoose(payload), _step; !(_step = _iterator()).done;) {
600
604
  var element = _step.value;
601
605
  for (var key in element) {
606
+ if (key === 'IsDebug') continue;
602
607
  if (!entityKeys.includes(key)) {
603
608
  throw new exception("'" + key + "' no es una propiedad v\xE1lida de la entidad");
604
609
  }