From e0216e9bbc5f5e59c0a168de7ea34107103d23a5 Mon Sep 17 00:00:00 2001 From: yash-learner Date: Sat, 28 Dec 2024 00:21:50 +0530 Subject: [PATCH] Fix note field rendering to handle undefined text value --- src/components/LabTest/CreateServiceRequest.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/LabTest/CreateServiceRequest.tsx b/src/components/LabTest/CreateServiceRequest.tsx index ccec296c329..f52e5519a51 100644 --- a/src/components/LabTest/CreateServiceRequest.tsx +++ b/src/components/LabTest/CreateServiceRequest.tsx @@ -100,7 +100,7 @@ export default function CreateServiceRequest({ placeholder="Type your note here." id="note" className="bg-white" - value={note[0].text} + value={note[0]?.text || ""} onChange={handleNoteChange} />