From fe14bb7e83af53151fcc810c7691cdf4c8a1a2db Mon Sep 17 00:00:00 2001 From: Zack Stickles Date: Fri, 14 Aug 2020 13:50:21 -0700 Subject: [PATCH] fix: only show date modified if Gatsby sees it as valid --- src/components/RelatedContentModules/PageUpdated.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/components/RelatedContentModules/PageUpdated.js b/src/components/RelatedContentModules/PageUpdated.js index d528bfe19..71af63786 100644 --- a/src/components/RelatedContentModules/PageUpdated.js +++ b/src/components/RelatedContentModules/PageUpdated.js @@ -9,6 +9,9 @@ const PageUpdated = ({ page }) => { fields: { gitAuthorTime }, } = page; + // If there is no date available, do not render the component + if (gitAuthorTime === 'Invalid date') return null; + return (