Fix crash when converting form fields with a schema that doesn't contain a certain field
This commit is contained in:
parent
401c12732f
commit
cf33680b1e
|
@ -955,7 +955,9 @@ export const buildFormSchema = (component, asset) => {
|
|||
const patched = convertOldFieldFormat(component.fields || [])
|
||||
patched?.forEach(({ field, active }) => {
|
||||
if (!active) return
|
||||
schema[field] = { type: info?.schema[field].type }
|
||||
if (info?.schema[field]) {
|
||||
schema[field] = { type: info?.schema[field].type }
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue