From 312e0c4834b772a948a033d880d7858b3e0bb6a8 Mon Sep 17 00:00:00 2001 From: Gabriel Luiz Freitas Almeida Date: Mon, 12 Jun 2023 17:05:05 -0300 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix(GenericNode):=20set=20valida?= =?UTF-8?q?tionStatus=20to=20null=20when=20relevantData=20is=20null=20This?= =?UTF-8?q?=20change=20fixes=20a=20bug=20where=20the=20validationStatus=20?= =?UTF-8?q?state=20was=20not=20being=20set=20to=20null=20when=20relevantDa?= =?UTF-8?q?ta=20was=20null.=20This=20caused=20the=20validationStatus=20to?= =?UTF-8?q?=20retain=20its=20previous=20value,=20which=20could=20lead=20to?= =?UTF-8?q?=20incorrect=20validation=20results=20being=20displayed.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/frontend/src/CustomNodes/GenericNode/index.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/frontend/src/CustomNodes/GenericNode/index.tsx b/src/frontend/src/CustomNodes/GenericNode/index.tsx index 864cf6dab..df92763f2 100644 --- a/src/frontend/src/CustomNodes/GenericNode/index.tsx +++ b/src/frontend/src/CustomNodes/GenericNode/index.tsx @@ -64,6 +64,8 @@ export default function GenericNode({ if (relevantData) { // Extract validation information from relevantData and update the validationStatus state setValidationStatus(relevantData); + } else { + setValidationStatus(null); } }, [sseData, data.id]);