@sinclair/typebox 0.32.27 → 0.32.28
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.
|
@@ -89,12 +89,12 @@ function FromNot(schema, references, path, value) {
|
|
|
89
89
|
// prettier-ignore
|
|
90
90
|
function FromObject(schema, references, path, value) {
|
|
91
91
|
const defaulted = Default(schema, path, value);
|
|
92
|
-
if (!(0, index_7.IsStandardObject)(
|
|
92
|
+
if (!(0, index_7.IsStandardObject)(defaulted))
|
|
93
93
|
return defaulted;
|
|
94
94
|
const knownKeys = (0, index_3.KeyOfPropertyKeys)(schema);
|
|
95
95
|
const knownProperties = { ...defaulted };
|
|
96
96
|
for (const key of knownKeys)
|
|
97
|
-
if (key in
|
|
97
|
+
if (key in knownProperties) {
|
|
98
98
|
knownProperties[key] = Visit(schema.properties[key], references, `${path}/${key}`, knownProperties[key]);
|
|
99
99
|
}
|
|
100
100
|
if (!(0, type_1.IsSchema)(schema.additionalProperties)) {
|
|
@@ -90,12 +90,12 @@ function FromNot(schema, references, path, value) {
|
|
|
90
90
|
// prettier-ignore
|
|
91
91
|
function FromObject(schema, references, path, value) {
|
|
92
92
|
const defaulted = Default(schema, path, value);
|
|
93
|
-
if (!IsStandardObject(
|
|
93
|
+
if (!IsStandardObject(defaulted))
|
|
94
94
|
return defaulted;
|
|
95
95
|
const knownKeys = KeyOfPropertyKeys(schema);
|
|
96
96
|
const knownProperties = { ...defaulted };
|
|
97
97
|
for (const key of knownKeys)
|
|
98
|
-
if (key in
|
|
98
|
+
if (key in knownProperties) {
|
|
99
99
|
knownProperties[key] = Visit(schema.properties[key], references, `${path}/${key}`, knownProperties[key]);
|
|
100
100
|
}
|
|
101
101
|
if (!IsSchema(schema.additionalProperties)) {
|