aboutsummaryrefslogtreecommitdiffstats
path: root/Sources/WireGuardKit/PacketTunnelSettingsGenerator.swift
diff options
context:
space:
mode:
Diffstat (limited to 'Sources/WireGuardKit/PacketTunnelSettingsGenerator.swift')
-rw-r--r--Sources/WireGuardKit/PacketTunnelSettingsGenerator.swift4
1 files changed, 2 insertions, 2 deletions
diff --git a/Sources/WireGuardKit/PacketTunnelSettingsGenerator.swift b/Sources/WireGuardKit/PacketTunnelSettingsGenerator.swift
index 1e21490..9efe1fa 100644
--- a/Sources/WireGuardKit/PacketTunnelSettingsGenerator.swift
+++ b/Sources/WireGuardKit/PacketTunnelSettingsGenerator.swift
@@ -31,7 +31,7 @@ class PacketTunnelSettingsGenerator {
switch result {
case .success(.some(let endpoint)):
- if case .name(_, _) = endpoint.host { assert(false, "Endpoint is not resolved") }
+ if case .name = endpoint.host { assert(false, "Endpoint is not resolved") }
wgSettings.append("endpoint=\(endpoint.stringRepresentation)\n")
case .success(.none):
break
@@ -58,7 +58,7 @@ class PacketTunnelSettingsGenerator {
wgSettings.append("preshared_key=\(preSharedKey)\n")
}
if let endpoint = try? resolvedEndpoints[index]?.withReresolvedIP() {
- if case .name(_, _) = endpoint.host { assert(false, "Endpoint is not resolved") }
+ if case .name = endpoint.host { assert(false, "Endpoint is not resolved") }
wgSettings.append("endpoint=\(endpoint.stringRepresentation)\n")
}
let persistentKeepAlive = peer.persistentKeepAlive ?? 0