codify-plugin-lib 1.0.174 → 1.0.175

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.
@@ -1,4 +1,5 @@
1
1
  import { Ajv } from 'ajv';
2
+ import cleanDeep from 'clean-deep';
2
3
  import { ParameterOperation, ResourceOperation } from 'codify-schemas';
3
4
  import { Plan } from '../plan/plan.js';
4
5
  import { ConfigParser } from './config-parser.js';
@@ -36,7 +37,9 @@ export class ResourceController {
36
37
  this.addDefaultValues(parameters);
37
38
  if (this.schemaValidator) {
38
39
  // Schema validator uses pre transformation parameters
39
- const isValid = this.schemaValidator(originalParameters);
40
+ const isValid = this.schemaValidator(
41
+ // @ts-expect-error Non esm package
42
+ cleanDeep(originalParameters, { nullValues: true }));
40
43
  if (!isValid) {
41
44
  return {
42
45
  isValid: false,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codify-plugin-lib",
3
- "version": "1.0.174",
3
+ "version": "1.0.175",
4
4
  "description": "Library plugin library",
5
5
  "main": "dist/index.js",
6
6
  "typings": "dist/index.d.ts",
@@ -22,7 +22,8 @@
22
22
  "uuid": "^10.0.0",
23
23
  "lodash.isequal": "^4.5.0",
24
24
  "nanoid": "^5.0.9",
25
- "strip-ansi": "^7.1.0"
25
+ "strip-ansi": "^7.1.0",
26
+ "clean-deep": "^3.4.0"
26
27
  },
27
28
  "devDependencies": {
28
29
  "@oclif/prettier-config": "^0.2.1",
@@ -33,6 +34,7 @@
33
34
  "@types/sinon": "^17.0.3",
34
35
  "@types/uuid": "^10.0.0",
35
36
  "@types/lodash.isequal": "^4.5.8",
37
+ "@types/deep-clean": "",
36
38
  "chai-as-promised": "^7.1.1",
37
39
  "vitest": "^3.0.5",
38
40
  "vitest-mock-extended": "^1.3.1",
@@ -1,4 +1,5 @@
1
1
  import { Ajv, ValidateFunction } from 'ajv';
2
+ import cleanDeep from 'clean-deep';
2
3
  import {
3
4
  ParameterOperation,
4
5
  ResourceConfig,
@@ -63,7 +64,10 @@ export class ResourceController<T extends StringIndexedObject> {
63
64
 
64
65
  if (this.schemaValidator) {
65
66
  // Schema validator uses pre transformation parameters
66
- const isValid = this.schemaValidator(originalParameters);
67
+ const isValid = this.schemaValidator(
68
+ // @ts-expect-error Non esm package
69
+ cleanDeep(originalParameters, { nullValues: true })
70
+ );
67
71
 
68
72
  if (!isValid) {
69
73
  return {