From 32688892bcc01b3c7795d24262f9376ae843ccf5 Mon Sep 17 00:00:00 2001 From: Jamie Hewitt Date: Tue, 5 Oct 2021 14:19:51 +0300 Subject: [PATCH] Using optional chaining on the description to solve search bug (#903) --- src/components/molecules/AssetTeaser.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/molecules/AssetTeaser.tsx b/src/components/molecules/AssetTeaser.tsx index b1b249642..a7e912b00 100644 --- a/src/components/molecules/AssetTeaser.tsx +++ b/src/components/molecules/AssetTeaser.tsx @@ -50,7 +50,7 @@ const AssetTeaser: React.FC = ({
{removeMarkdown( - attributes?.additionalInformation?.description.substring( + attributes?.additionalInformation?.description?.substring( 0, 300 ) || ''