@@ -31,11 +31,16 @@ function convertSchema(schema, path, parent, parentPath) {
3131 schema = convertTypes ( schema ) ;
3232 schema = convertDependencies ( schema ) ;
3333 schema = rewriteIfThenElse ( schema ) ;
34+ schema = rewriteExclusiveMinMax ( schema ) ;
3435
3536 if ( typeof schema [ 'patternProperties' ] === 'object' ) {
3637 schema = convertPatternProperties ( schema ) ;
3738 }
3839
40+ if ( schema . type === 'array' && typeof schema . items === 'undefined' ) {
41+ schema . items = { } ;
42+ }
43+ 3944 return schema ;
4045}
4146
@@ -159,6 +164,18 @@ oneOf: [allOf: [X, Y], allOf: [not: X, Z]]
159164 delete schema . if ;
160165 delete schema . then ;
161166 delete schema . else ;
167+ }
168+ return schema ;
169+ }
170+ 171+ function rewriteExclusiveMinMax ( schema ) {
172+ if ( typeof schema . exclusiveMaximum === 'number' ) {
173+ schema . maximum = schema . exclusiveMaximum ;
174+ schema . exclusiveMaximum = true ;
175+ }
176+ if ( typeof schema . exclusiveMinimum === 'number' ) {
177+ schema . minimum = schema . exclusiveMinimum ;
178+ schema . exclusiveMinimum = true ;
162179 }
163180 return schema ;
164181}
0 commit comments