From d15224ce23c056e344e2ac361238191071962fbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matou=C5=A1=20Ku=C4=8Dera?= Date: Tue, 7 Jan 2025 21:52:18 +0100 Subject: [PATCH] fix: make empty arrays in config not suck --- src/components/config/ConfigDocBlock.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/config/ConfigDocBlock.tsx b/src/components/config/ConfigDocBlock.tsx index 2a3763b8..51824a7f 100644 --- a/src/components/config/ConfigDocBlock.tsx +++ b/src/components/config/ConfigDocBlock.tsx @@ -61,7 +61,7 @@ const parseDefault = ( const hash = createUrlHash(parentKey, name); useBrokenLinks().collectAnchor(hash); - if (value[0] === "[" && value[value.length - 1] === "]") { + if (value[0] === "[" && value[value.length - 1] === "]" && value !== "[]") { const items: (string | ReactNode)[] = value .replace("[", "") .replace("]", "")