diff --git a/docs/change-log.md b/docs/change-log.md index 310ec157..57996ba5 100644 --- a/docs/change-log.md +++ b/docs/change-log.md @@ -8,6 +8,7 @@ outline: deep * Check to make sure a job handler exists before allowing a job to be created. * Implemented: CLI should let you search for jobs by handler name #125 * Fixed a bug in job worker where it could not error properly from a job handler that didn't exist. +* Fixed: enum should not have a length field in the schema validator #130 ## 2024-04-25 * Fixed a bug where ving record fields of type 'int' were not being initialized properly. diff --git a/ving/schema/validator.mjs b/ving/schema/validator.mjs index 608ca75a..108d6b63 100644 --- a/ving/schema/validator.mjs +++ b/ving/schema/validator.mjs @@ -278,7 +278,7 @@ export const validatePropUnique = (prop, schema) => { * validatePropLength(prop, schema) */ export const validatePropLength = (prop, schema) => { - if (!['id', 'enum', 'string'].includes(prop.type)) { + if (!['id', 'string'].includes(prop.type)) { if ('length' in prop) throw ving.ouch(442, `${schema.kind}.props.${prop.name}.length should not exist.`); return;