From ebca114c2e69e36048be919bffe3c9d2a09ba323 Mon Sep 17 00:00:00 2001 From: Notselwyn <68616630+Notselwyn@users.noreply.github.com> Date: Thu, 28 Dec 2023 16:15:46 +0100 Subject: [PATCH] fix: optimized (now redundant) code --- SafeExamBrowser.Runtime/Operations/SessionIntegrityOperation.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SafeExamBrowser.Runtime/Operations/SessionIntegrityOperation.cs b/SafeExamBrowser.Runtime/Operations/SessionIntegrityOperation.cs index 1649df91..4d0696a3 100644 --- a/SafeExamBrowser.Runtime/Operations/SessionIntegrityOperation.cs +++ b/SafeExamBrowser.Runtime/Operations/SessionIntegrityOperation.cs @@ -77,7 +77,7 @@ namespace SafeExamBrowser.Runtime.Operations foreach (var cursor in cursors.Where(c => !string.IsNullOrWhiteSpace(c))) { success &= registry.TryRead(RegistryValue.UserHive.Cursors_Key, cursor, out var value); - success &= value == default || !(value is string) || (value is string path && (string.IsNullOrWhiteSpace(path) || IsValidCursorPath(path))); + success &= !(value is string) || (value is string path && (string.IsNullOrWhiteSpace(path) || IsValidCursorPath(path))); if (!success) {