From c5adcda1e3b40b3bf2a39440286d1fe3dd23e473 Mon Sep 17 00:00:00 2001 From: SektorDV <35644259+SektorDV@users.noreply.github.com> Date: Fri, 20 Aug 2021 13:14:14 +0200 Subject: [PATCH] Fix dashboard crash when no channels exist (#1311) * channel value test fix * update snapshots * Fix dashboard crashing when no channels exist (#1305) * add optional chaining to ids * lint fix * channel value test fix * Fix dashboard crashing when no channels exist (#1305) * add optional chaining to ids * lint fix * channel value test fix --- src/components/AppLayout/AppLayout.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/components/AppLayout/AppLayout.tsx b/src/components/AppLayout/AppLayout.tsx index b22f4dc2d..f27f1c4dd 100644 --- a/src/components/AppLayout/AppLayout.tsx +++ b/src/components/AppLayout/AppLayout.tsx @@ -198,7 +198,7 @@ const AppLayout: React.FC = ({ children }) => { {isPickerActive && ( )} @@ -207,7 +207,7 @@ const AppLayout: React.FC = ({ children }) => { user={user} onLogout={logout} onProfileClick={() => - navigate(staffMemberDetailsUrl(user.id)) + navigate(staffMemberDetailsUrl(user?.id)) } onThemeToggle={toggleTheme} />