From f08ae09efc61e2c5b0635084f8632e0d9b11dc09 Mon Sep 17 00:00:00 2001 From: Daniel Lautzenheiser Date: Fri, 14 Jul 2023 09:50:46 -0400 Subject: [PATCH] fix: handle bad data in list preview --- packages/core/src/widgets/list/ListPreview.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/core/src/widgets/list/ListPreview.tsx b/packages/core/src/widgets/list/ListPreview.tsx index 3a46153a..e9653322 100644 --- a/packages/core/src/widgets/list/ListPreview.tsx +++ b/packages/core/src/widgets/list/ListPreview.tsx @@ -38,6 +38,10 @@ function renderNestedList( } const ListPreview: FC> = ({ field, value }) => { + if (!Array.isArray(value)) { + return null; + } + return (