json-schema-library
Advanced tools
Comparing version 10.0.0-rc4 to 10.0.0-rc5
@@ -27,3 +27,5 @@ import { isJsonError } from "./types"; | ||
if (schema.additionalItems && !isObject(schema.items)) { | ||
return [draft.createNode(schema.additionalItems).resolveRef().schema]; | ||
// we fallback to a string if no schema is defined - might be subject for configuration | ||
const additionalSchema = schema.additionalItems === true ? { type: "string" } : schema.additionalItems; | ||
return [draft.createNode(additionalSchema).resolveRef().schema]; | ||
} | ||
@@ -30,0 +32,0 @@ // array.items[] exceeded |
@@ -34,3 +34,6 @@ import { Draft } from "./draft"; | ||
if (schema.additionalItems && !isObject(schema.items)) { | ||
return [draft.createNode(schema.additionalItems).resolveRef().schema]; | ||
// we fallback to a string if no schema is defined - might be subject for configuration | ||
const additionalSchema: JsonSchema = | ||
schema.additionalItems === true ? { type: "string" } : schema.additionalItems; | ||
return [draft.createNode(additionalSchema).resolveRef().schema]; | ||
} | ||
@@ -37,0 +40,0 @@ |
{ | ||
"name": "json-schema-library", | ||
"version": "10.0.0-rc4", | ||
"version": "10.0.0-rc5", | ||
"description": "Customizable and hackable json-validator and json-schema utilities for traversal, data generation and validation", | ||
@@ -5,0 +5,0 @@ "module": "dist/module/index.js", |
Sorry, the diff of this file is too big to display
1783992
40675