From e5a01976cb665b824b2ad6426a2c52a5bd0964e6 Mon Sep 17 00:00:00 2001
From: it-fixcomart <it@fixcomart.co.id>
Date: Sat, 27 Jul 2024 08:27:54 +0700
Subject: <iman> add feature category lob

---
 src/lib/home/components/CategoryDynamic.jsx | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'src/lib/home/components/CategoryDynamic.jsx')

diff --git a/src/lib/home/components/CategoryDynamic.jsx b/src/lib/home/components/CategoryDynamic.jsx
index bbba2ceb..6ab03ec3 100644
--- a/src/lib/home/components/CategoryDynamic.jsx
+++ b/src/lib/home/components/CategoryDynamic.jsx
@@ -21,7 +21,7 @@ const CategoryDynamic = () => {
           const countLevel1 = await odooApi('GET', `/api/v1/category/numFound?parent_id=${category.categoryIdI}`);
           // console.log("countLevel1.child",countLevel1)
           
-          updatedCategoryData[category.categoryIdI] = countLevel1.numFound;
+          updatedCategoryData[category.categoryIdI] = countLevel1?.numFound;
           
           
           // Calculate level 2 products for each sub-category
-- 
cgit v1.2.3

