From 6e6dd219f4b05ad413ce3d39807a4d69110f9b6f Mon Sep 17 00:00:00 2001 From: James Gunn Date: Mon, 15 Jan 2024 11:38:04 +0000 Subject: [PATCH] Handle a null TrnVerificationLevel when comparing to required level (#779) --- .../Pages/SignIn/TrnInUseChooseEmail.cshtml.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dotnet-authserver/src/TeacherIdentity.AuthServer/Pages/SignIn/TrnInUseChooseEmail.cshtml.cs b/dotnet-authserver/src/TeacherIdentity.AuthServer/Pages/SignIn/TrnInUseChooseEmail.cshtml.cs index 4428a93b3..5ae899cd5 100644 --- a/dotnet-authserver/src/TeacherIdentity.AuthServer/Pages/SignIn/TrnInUseChooseEmail.cshtml.cs +++ b/dotnet-authserver/src/TeacherIdentity.AuthServer/Pages/SignIn/TrnInUseChooseEmail.cshtml.cs @@ -69,7 +69,7 @@ public async Task OnPost() user.EmailAddress = Email; bool trnVerificationLevelChanged = false; - if (user.TrnVerificationLevel < journeyTrnVerificationLevel) + if ((user.TrnVerificationLevel ?? TrnVerificationLevel.Low) < journeyTrnVerificationLevel) { user.TrnVerificationLevel = journeyTrnVerificationLevel; trnVerificationLevelChanged = true;