From 2ab58116026644f545be77f5ebc78736d7123e2f Mon Sep 17 00:00:00 2001 From: Teemu Hiltunen Date: Tue, 24 Oct 2023 12:24:49 +0300 Subject: [PATCH] HAI-2057 removed unnecessary useEffect for Hanke vaihe --- src/domain/hanke/edit/HankeFormPerustiedot.tsx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/domain/hanke/edit/HankeFormPerustiedot.tsx b/src/domain/hanke/edit/HankeFormPerustiedot.tsx index c8d2786fa..107ec9285 100644 --- a/src/domain/hanke/edit/HankeFormPerustiedot.tsx +++ b/src/domain/hanke/edit/HankeFormPerustiedot.tsx @@ -1,4 +1,4 @@ -import React, { useEffect } from 'react'; +import React from 'react'; import { useTranslation, Trans } from 'react-i18next'; import { Tooltip, TextArea, SelectionGroup, RadioButton } from 'hds-react'; import { $enum } from 'ts-enum-util'; @@ -20,13 +20,12 @@ const HankeFormPerustiedot: React.FC> = ({ formData, }) => { const { t } = useTranslation(); - const { watch, setValue } = useFormContext(); + const { watch } = useFormContext(); const { JOHTOSELVITYSHAKEMUS } = useLocalizedRoutes(); useFormPage(); // Subscribe to vaihe changes in order to update the selected radio button const hankeVaiheField = watch(FORMFIELD.VAIHE); - useEffect(() => {}, [hankeVaiheField, setValue]); return (