From e804b3eb523ac06ad7f2513e75ca11375fe9d2fe Mon Sep 17 00:00:00 2001 From: patrickwebsdev Date: Wed, 6 Nov 2024 22:37:17 -0300 Subject: [PATCH] fix: minor fix pueblo card --- src/app/casos-activos/ofertas/page.js | 2 +- src/app/casos-activos/solicitudes/page.js | 2 +- src/components/OfferCard.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/app/casos-activos/ofertas/page.js b/src/app/casos-activos/ofertas/page.js index d130ffb6..73c24326 100644 --- a/src/app/casos-activos/ofertas/page.js +++ b/src/app/casos-activos/ofertas/page.js @@ -137,7 +137,7 @@ export default function Ofertas() { className="bg-green-500 text-white px-4 py-2 rounded hover:bg-green-600 flex items-center gap-2 whitespace-nowrap" > - Ofrecer ayuda a {filtroData.pueblo === 'todos' ? '' : towns[filtroData.pueblo - 1].name} + Ofrecer ayuda ) : ( diff --git a/src/app/casos-activos/solicitudes/page.js b/src/app/casos-activos/solicitudes/page.js index 7c5caf8b..eefabc6f 100644 --- a/src/app/casos-activos/solicitudes/page.js +++ b/src/app/casos-activos/solicitudes/page.js @@ -177,7 +177,7 @@ export default function Solicitudes() { className="bg-green-500 text-white px-4 py-2 rounded hover:bg-green-600 flex items-center gap-2 whitespace-nowrap" > - Ofrecer ayuda a {filtroData.pueblo === 'todos' ? '' : towns[filtroData.pueblo - 1].name} + Ofrecer ayuda a {filtroData.pueblo === 'todos' ? '' : towns[filtroData.pueblo - 1]?.name} ) : ( diff --git a/src/components/OfferCard.js b/src/components/OfferCard.js index 01cd51fd..d68aeace 100644 --- a/src/components/OfferCard.js +++ b/src/components/OfferCard.js @@ -102,7 +102,7 @@ export default function OfferCard({
- Pueblo: {towns[caso.town_id - 1].name || ''} + Pueblo: {towns[caso.town_id - 1]?.name || ''}
)}