From b191d0a0c95608b09efb39e87cdddc3ce215c142 Mon Sep 17 00:00:00 2001 From: Jordan Dominion Date: Thu, 23 Nov 2023 19:37:35 -0500 Subject: [PATCH] Nullify `SemaphoreSlimContext` --- src/Tgstation.Server.Host/Utils/SemaphoreSlimContext.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/Tgstation.Server.Host/Utils/SemaphoreSlimContext.cs b/src/Tgstation.Server.Host/Utils/SemaphoreSlimContext.cs index 4339515859..e9a40d7c68 100644 --- a/src/Tgstation.Server.Host/Utils/SemaphoreSlimContext.cs +++ b/src/Tgstation.Server.Host/Utils/SemaphoreSlimContext.cs @@ -2,8 +2,6 @@ using System.Threading; using System.Threading.Tasks; -#nullable disable - namespace Tgstation.Server.Host.Utils { /// @@ -30,7 +28,7 @@ namespace Tgstation.Server.Host.Utils /// The to lock. /// The result of the lock attempt. /// A for the lock on success, or if it was not acquired. - public static SemaphoreSlimContext TryLock(SemaphoreSlim semaphore, out bool locked) + public static SemaphoreSlimContext? TryLock(SemaphoreSlim semaphore, out bool locked) { ArgumentNullException.ThrowIfNull(semaphore); locked = semaphore.Wait(TimeSpan.Zero);