From c53bdf75730b955d37fc21e47504aae23014809f Mon Sep 17 00:00:00 2001 From: Greg Rushton Date: Thu, 19 Oct 2023 08:30:00 -0400 Subject: [PATCH 1/2] fix so display --- src/pages/user_profile/ResearcherStatus.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/pages/user_profile/ResearcherStatus.js b/src/pages/user_profile/ResearcherStatus.js index 32166dd8e..ed8ba3424 100644 --- a/src/pages/user_profile/ResearcherStatus.js +++ b/src/pages/user_profile/ResearcherStatus.js @@ -32,9 +32,10 @@ export default function ResearcherStatus(props) { setHasCard(false); } else { - const signingOfficialUser = await User.getById(user.libraryCards[0].institution.createUserId); + const signingOfficialUsers = await User.getSOsForCurrentUser(); setIssuedOn(user.libraryCards[0].createDate); - setIssuedBy(signingOfficialUser.displayName); + const names = signingOfficialUsers.map(so => so.displayName); + setIssuedBy(names.join(', ')); } } } catch (error) { From 55ed2ee3d3a21418c06aa90a94931cdc048f8177 Mon Sep 17 00:00:00 2001 From: Greg Rushton Date: Thu, 19 Oct 2023 08:35:42 -0400 Subject: [PATCH 2/2] fix equals check --- src/pages/user_profile/ResearcherStatus.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/user_profile/ResearcherStatus.js b/src/pages/user_profile/ResearcherStatus.js index ed8ba3424..f1f959a04 100644 --- a/src/pages/user_profile/ResearcherStatus.js +++ b/src/pages/user_profile/ResearcherStatus.js @@ -28,7 +28,7 @@ export default function ResearcherStatus(props) { const init = async () => { try { if (!isNil(user) && !isNil(user.libraryCards)) { - if (user.libraryCards.length == 0) { + if (user.libraryCards.length === 0) { setHasCard(false); } else {