@mcpc-tech/core 0.3.33 → 0.3.34
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/index.cjs +2 -1
- package/index.mjs +2 -1
- package/package.json +1 -1
package/index.cjs
CHANGED
|
@@ -18033,7 +18033,8 @@ var ajv = new import_ajv2.Ajv({
|
|
|
18033
18033
|
import_ajv_formats2.default.default(ajv);
|
|
18034
18034
|
import_ajv_errors.default.default(ajv);
|
|
18035
18035
|
function validateSchema(data, schema) {
|
|
18036
|
-
const
|
|
18036
|
+
const cleanedSchema = cleanToolSchema(schema);
|
|
18037
|
+
const validate = ajv.compile(cleanedSchema);
|
|
18037
18038
|
if (!validate(data)) {
|
|
18038
18039
|
const errors = validate.errors;
|
|
18039
18040
|
const customErrors = errors.filter((err) => err.keyword === "errorMessage");
|
package/index.mjs
CHANGED
|
@@ -18021,7 +18021,8 @@ var ajv = new Ajv2({
|
|
|
18021
18021
|
addFormats.default(ajv);
|
|
18022
18022
|
ajvErrors.default(ajv);
|
|
18023
18023
|
function validateSchema(data, schema) {
|
|
18024
|
-
const
|
|
18024
|
+
const cleanedSchema = cleanToolSchema(schema);
|
|
18025
|
+
const validate = ajv.compile(cleanedSchema);
|
|
18025
18026
|
if (!validate(data)) {
|
|
18026
18027
|
const errors = validate.errors;
|
|
18027
18028
|
const customErrors = errors.filter((err) => err.keyword === "errorMessage");
|