diff --git a/web_client/src/components/options/ConfigWindow.tsx b/web_client/src/components/options/ConfigWindow.tsx index f5a2ebeb..a8738c6c 100644 --- a/web_client/src/components/options/ConfigWindow.tsx +++ b/web_client/src/components/options/ConfigWindow.tsx @@ -224,7 +224,8 @@ const ConfigWindow: React.FC = () => { const handleAddItem = (key: string, defaultValue: PossibleConfigValue) => { setConfigData((prevData) => { const currentValue = prevData[key]; - const newValue = Array.isArray(currentValue) ? [...currentValue, defaultValue] : [defaultValue]; + const clonedDefault = structuredClone(defaultValue); + const newValue = Array.isArray(currentValue) ? [...currentValue, clonedDefault] : [clonedDefault]; return { ...prevData, [key]: newValue,