pg-mvc-service 2.0.82 → 2.0.83

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.
@@ -459,8 +459,10 @@ class RequestType extends ReqResType_1.default {
459
459
  switch (property.item.enumType) {
460
460
  case 'number':
461
461
  case 'number?':
462
+ console.log(value);
463
+ console.log(this.isNumber(value));
462
464
  if (this.isNumber(value) === false) {
463
- this.throwInputError("NUMBER_31", keys, value);
465
+ this.throwInputError("NUMBER_31", [...keys, i], value);
464
466
  }
465
467
  toEnumValue.push(Number(value));
466
468
  break;
@@ -474,12 +476,12 @@ class RequestType extends ReqResType_1.default {
474
476
  toEnumValue.push(value);
475
477
  break;
476
478
  default:
477
- this.throwInputError("STRING_31", keys, value);
479
+ this.throwInputError("STRING_31", [...keys, i], value);
478
480
  }
479
481
  break;
480
482
  }
481
483
  if (Object.keys(property.item.enums).includes(value.toString()) === false) {
482
- this.throwInputError("ENUM_32", keys, value);
484
+ this.throwInputError("ENUM_32", [...keys, i], value);
483
485
  }
484
486
  this.changeBody([...keys, i], toEnumValue);
485
487
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pg-mvc-service",
3
- "version": "2.0.82",
3
+ "version": "2.0.83",
4
4
  "description": "",
5
5
  "homepage": "https://github.com/n-daira/npm-pack_mvc-service#readme",
6
6
  "bugs": {
@@ -479,8 +479,10 @@ export class RequestType extends ReqResType {
479
479
  switch (property.item.enumType) {
480
480
  case 'number':
481
481
  case 'number?':
482
+ console.log(value);
483
+ console.log(this.isNumber(value));
482
484
  if (this.isNumber(value) === false) {
483
- this.throwInputError("NUMBER_31", keys, value);
485
+ this.throwInputError("NUMBER_31", [...keys, i], value);
484
486
  }
485
487
  toEnumValue.push(Number(value));
486
488
  break;
@@ -494,13 +496,13 @@ export class RequestType extends ReqResType {
494
496
  toEnumValue.push(value);
495
497
  break;
496
498
  default:
497
- this.throwInputError("STRING_31", keys, value);
499
+ this.throwInputError("STRING_31", [...keys, i], value);
498
500
  }
499
501
  break;
500
502
  }
501
503
 
502
504
  if (Object.keys(property.item.enums).includes(value.toString()) === false) {
503
- this.throwInputError("ENUM_32", keys, value);
505
+ this.throwInputError("ENUM_32", [...keys, i], value);
504
506
  }
505
507
  this.changeBody([...keys, i], toEnumValue);
506
508
  }