From e3c5ecd5ff1ff3cb5f6a66ebb726e6d5058cd4cd Mon Sep 17 00:00:00 2001 From: JP Dillingham Date: Sun, 15 Feb 2026 10:44:15 -0600 Subject: make behavior of a null response from client more obvious --- src/slskd/Integrations/VPN/VPNService.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/slskd/Integrations/VPN/VPNService.cs b/src/slskd/Integrations/VPN/VPNService.cs index 95d897a3..1f59db99 100644 --- a/src/slskd/Integrations/VPN/VPNService.cs +++ b/src/slskd/Integrations/VPN/VPNService.cs @@ -170,8 +170,12 @@ public class VPNService : IDisposable try { - status = await Client.GetStatusAsync() - ?? throw new VPNClientException("VPN client returned an invalid response"); + status = await Client.GetStatusAsync(); + + if (status is null) + { + throw new VPNClientException("VPN client returned an invalid response"); + } } catch (Exception ex) { -- cgit v1.2.3