From 9deadbed533951f400aa2f626af04ccac21fe865 Mon Sep 17 00:00:00 2001 From: Stephen Smith Date: Mon, 2 Aug 2021 16:45:55 -0400 Subject: [PATCH] 17690: Add guard against undefined user in ssh key page Arvados-DCO-1.1-Signed-off-by: Stephen Smith --- src/views/ssh-key-panel/ssh-key-panel.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/ssh-key-panel/ssh-key-panel.tsx b/src/views/ssh-key-panel/ssh-key-panel.tsx index 0c86b364..672b1bf3 100644 --- a/src/views/ssh-key-panel/ssh-key-panel.tsx +++ b/src/views/ssh-key-panel/ssh-key-panel.tsx @@ -11,7 +11,7 @@ import { SshKeyPanelRoot, SshKeyPanelRootDataProps, SshKeyPanelRootActionProps } const mapStateToProps = (state: RootState): SshKeyPanelRootDataProps => { const sshKeys = state.auth.sshKeys.filter((key) => { - return key.authorizedUserUuid == state.auth.user.uuid; + return key.authorizedUserUuid == (state.auth.user ? state.auth.user.uuid : null); }); return { -- 2.30.2