From afaf39b3287bfcf78014a3eb58c6a5722080caea Mon Sep 17 00:00:00 2001 From: Milos Despotovic Date: Tue, 20 Aug 2024 16:18:48 -0700 Subject: [PATCH] Fix bug sending wrong correspondenceid --- .../components/FOI/customComponents/ContactApplicant/index.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/forms-flow-web/src/components/FOI/customComponents/ContactApplicant/index.tsx b/forms-flow-web/src/components/FOI/customComponents/ContactApplicant/index.tsx index eca03acdf..f5a25b99c 100644 --- a/forms-flow-web/src/components/FOI/customComponents/ContactApplicant/index.tsx +++ b/forms-flow-web/src/components/FOI/customComponents/ContactApplicant/index.tsx @@ -138,6 +138,7 @@ export const ContactApplicant = ({ setFiles([]); setEditorValue(""); setDraftCorrespondence({}); + setCorrespondenceId(null); setSelectedEmails([]); setCurrentTemplate(0); } @@ -585,7 +586,7 @@ export const ContactApplicant = ({ - const [correspondenceId, setCorrespondenceId] = useState(0); + const [correspondenceId, setCorrespondenceId] = useState(null); const editDraft = async (i : any) => { setEditMode(true);