From 1a20b38418e8d06d5be53c5dd903c44fc34da31b Mon Sep 17 00:00:00 2001 From: suvarnakale Date: Fri, 10 May 2024 14:58:09 +0530 Subject: [PATCH] Issue #PS-320 undefined issue fixed --- src/pages/Dashboard.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/Dashboard.tsx b/src/pages/Dashboard.tsx index 5b425966..143cea7b 100644 --- a/src/pages/Dashboard.tsx +++ b/src/pages/Dashboard.tsx @@ -588,7 +588,7 @@ const Dashboard: React.FC = () => { console.log(percentageAttendance); const currentAttendance = percentageAttendance?.[todayDate]; // let currentPercentAttendance = 'N/A'; - const presentPercentage = parseFloat(currentAttendance.present_percentage); + const presentPercentage = parseFloat(currentAttendance?.present_percentage); // Determine the color based on presentPercentage value let pathColor; // Default color (green)