From 981d0c301c70bb7d06dfd423b5529f55922ab665 Mon Sep 17 00:00:00 2001 From: Shaun Hamilton Date: Mon, 24 Nov 2025 11:06:17 +0200 Subject: [PATCH] fix(client): only show missing prerequisites if signed in (#64047) Co-authored-by: moT01 <20648924+moT01@users.noreply.github.com> --- .../Challenges/exam-download/show.tsx | 22 +++++++++++-------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/client/src/templates/Challenges/exam-download/show.tsx b/client/src/templates/Challenges/exam-download/show.tsx index 558388e08ab..5e90d129bdd 100644 --- a/client/src/templates/Challenges/exam-download/show.tsx +++ b/client/src/templates/Challenges/exam-download/show.tsx @@ -228,6 +228,9 @@ function ShowExamDownload({ }; }); + const showPrereqAlert = + isSignedIn && !examIdsQuery.isLoading && !getExamsQuery.isLoading; + return ( @@ -246,15 +249,16 @@ function ShowExamDownload({ {title} - {missingPrerequisites.length > 0 ? ( - - ) : ( - -

{t('learn.exam.qualified')}

-
- )} + {showPrereqAlert && + (missingPrerequisites.length > 0 ? ( + + ) : ( + +

{t('learn.exam.qualified')}

+
+ ))}

{t('exam.download-header')}

{t('exam.explanation')}