From e5869d6fe82c93b70cacc87e5ed06a9c0064612d Mon Sep 17 00:00:00 2001 From: Olusegun Akintayo Date: Wed, 16 Mar 2022 12:10:07 +0400 Subject: [PATCH] Fix for connected sites throwing error if name is null. (#13974) * Fix for connected sites throwing error if name is null. Signed-off-by: Akintayo A. Olusegun * Reverted yarn.lock changes. Signed-off-by: Akintayo A. Olusegun --- .../ui/icon-with-fallback/icon-with-fallback.component.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/components/ui/icon-with-fallback/icon-with-fallback.component.js b/ui/components/ui/icon-with-fallback/icon-with-fallback.component.js index 62c1ba69f..cbf61b599 100644 --- a/ui/components/ui/icon-with-fallback/icon-with-fallback.component.js +++ b/ui/components/ui/icon-with-fallback/icon-with-fallback.component.js @@ -23,14 +23,14 @@ const IconWithFallback = ({ src={icon} style={style} className={className} - alt={name.length ? name : 'icon'} + alt={name || 'icon'} {...props} /> ) : ( - {name.length ? name.charAt(0).toUpperCase() : ''} + {name && name.length ? name.charAt(0).toUpperCase() : ''} ); };