aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJP Dillingham <jp@dillingham.me>2026-02-15 10:43:35 -0600
committerJP Dillingham <jp@dillingham.me>2026-02-15 10:43:35 -0600
commitbd9fb7485d4ef3383a0d2504f14ad3eebd6bae3e (patch)
tree519bf7faaaf027dce59872aae85e613c546f0070 /src
parent24b734299857c2a231918bcad02a3b06dbf3baf4 (diff)
downloadslskd-bd9fb7485d4ef3383a0d2504f14ad3eebd6bae3e.tar.gz
ensure Client is not null before attempting to check
Diffstat (limited to 'src')
-rw-r--r--src/slskd/Integrations/VPN/VPNService.cs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/slskd/Integrations/VPN/VPNService.cs b/src/slskd/Integrations/VPN/VPNService.cs
index ead0ce60..d82a8bfe 100644
--- a/src/slskd/Integrations/VPN/VPNService.cs
+++ b/src/slskd/Integrations/VPN/VPNService.cs
@@ -149,6 +149,11 @@ public class VPNService : IDisposable
private async Task CheckConnection()
{
+ if (Client is null)
+ {
+ throw new VPNClientException("VPN client not properly initialized; something went seriously wrong! Please report to GitHub.");
+ }
+
var options = OptionsMonitor.CurrentValue.Integration.Vpn;
bool isReadyNow = false;
VPNStatus status = new VPNStatus();