From 7f7057733a7a4d1fe82dfdda089b38287e6bb212 Mon Sep 17 00:00:00 2001 From: tc-imba Date: Tue, 2 Apr 2024 02:37:56 +0800 Subject: [PATCH] fix: hide awards if empty --- .../src/components/PageFragments/HomePage/Awards.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gatsby-theme-academic/src/components/PageFragments/HomePage/Awards.jsx b/gatsby-theme-academic/src/components/PageFragments/HomePage/Awards.jsx index c9c12c56..0b3bbc41 100644 --- a/gatsby-theme-academic/src/components/PageFragments/HomePage/Awards.jsx +++ b/gatsby-theme-academic/src/components/PageFragments/HomePage/Awards.jsx @@ -35,7 +35,7 @@ const AwardItem = (data) => { const Awards = () => { const siteMetadata = useSiteMetadata(); - if (!siteMetadata.awards) return null; + if (!siteMetadata.awards || siteMetadata.awards.length === 0) return null; return (

Awards & Scholarships