From 83b559d913af0611f0ca8c03b0a756fce75df66f Mon Sep 17 00:00:00 2001 From: Bowen Tan Date: Tue, 23 Nov 2021 14:31:57 +0800 Subject: [PATCH] small refactor --- .../src/components/ComponentForm/JsonSchemaForm/ObjectField.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/editor/src/components/ComponentForm/JsonSchemaForm/ObjectField.tsx b/packages/editor/src/components/ComponentForm/JsonSchemaForm/ObjectField.tsx index 594a45ef..2930882f 100644 --- a/packages/editor/src/components/ComponentForm/JsonSchemaForm/ObjectField.tsx +++ b/packages/editor/src/components/ComponentForm/JsonSchemaForm/ObjectField.tsx @@ -20,7 +20,7 @@ const ObjectField: React.FC = props => { key={name} schema={subSchema} label={subSchema.title || name} - formData={formData ? formData[name] : undefined} + formData={formData?.[name]} onChange={value => onChange({ ...formData,