node_modules/ajv/lib/dotjs/_limitProperties.js in trusty-cms-5.0.6 vs node_modules/ajv/lib/dotjs/_limitProperties.js in trusty-cms-5.0.7

- old
+ new

@@ -15,9 +15,12 @@ out += ' var schema' + ($lvl) + ' = ' + (it.util.getData($schema.$data, $dataLvl, it.dataPathArr)) + '; '; $schemaValue = 'schema' + $lvl; } else { $schemaValue = $schema; } + if (!($isData || typeof $schema == 'number')) { + throw new Error($keyword + ' must be number'); + } var $op = $keyword == 'maxProperties' ? '>' : '<'; out += 'if ( '; if ($isData) { out += ' (' + ($schemaValue) + ' !== undefined && typeof ' + ($schemaValue) + ' != \'number\') || '; }