From f767a242f7b9ccd98bb551349c0215d8a895599b Mon Sep 17 00:00:00 2001 From: Daniel Belcher Date: Thu, 16 Nov 2023 10:10:35 -0800 Subject: [PATCH] fix: name mismatch --- src/services/ui/src/components/RHF/FieldArray.tsx | 6 +++--- src/services/ui/src/components/RHF/FieldGroup.tsx | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/services/ui/src/components/RHF/FieldArray.tsx b/src/services/ui/src/components/RHF/FieldArray.tsx index 6824f1367a..1f5e2c59ef 100644 --- a/src/services/ui/src/components/RHF/FieldArray.tsx +++ b/src/services/ui/src/components/RHF/FieldArray.tsx @@ -31,9 +31,9 @@ export const RHFFieldArray = ( return (
{props.fields.map((SLOT) => { - const adjustedPrefix = - (props.groupNamePrefix ?? "") + `${props.name}.${index}.`; - const adjustedSlotName = adjustedPrefix + SLOT.name; + const prefix = `${props.name}.${index}.`; + const adjustedPrefix = (props.groupNamePrefix ?? "") + prefix; + const adjustedSlotName = prefix + SLOT.name; return ( ( return (
{props.fields.map((SLOT) => { - const adjustedPrefix = - (props.groupNamePrefix ?? "") + `${props.name}.${index}.`; - const adjustedSlotName = adjustedPrefix + SLOT.name; + const prefix = `${props.name}.${index}.`; + const adjustedPrefix = (props.groupNamePrefix ?? "") + prefix; + const adjustedSlotName = prefix + SLOT.name; return (