Restore generic VPN in TunnelKitVPNManagerStrategy

MockVPN was not compiling.

Partially revert e17224e61e
This commit is contained in:
Davide De Rosa 2023-03-17 21:16:48 +01:00
parent 26c34638cb
commit e7a98acf9c
1 changed files with 3 additions and 3 deletions

View File

@ -32,7 +32,7 @@ import TunnelKitOpenVPNCore
import PassepartoutCore import PassepartoutCore
import PassepartoutUtils import PassepartoutUtils
public class TunnelKitVPNManagerStrategy: VPNManagerStrategy { public class TunnelKitVPNManagerStrategy<VPNType: VPN>: VPNManagerStrategy where VPNType.Configuration == NetworkExtensionConfiguration, VPNType.Extra == NetworkExtensionExtra {
private struct AtomicState: Equatable { private struct AtomicState: Equatable {
let isEnabled: Bool let isEnabled: Bool
@ -52,7 +52,7 @@ public class TunnelKitVPNManagerStrategy: VPNManagerStrategy {
private let defaults: UserDefaults private let defaults: UserDefaults
private let vpn: NetworkExtensionVPN private let vpn: VPNType
private let dataCountInterval: TimeInterval private let dataCountInterval: TimeInterval
@ -73,7 +73,7 @@ public class TunnelKitVPNManagerStrategy: VPNManagerStrategy {
public init( public init(
appGroup: String, appGroup: String,
tunnelBundleIdentifier: @escaping (VPNProtocolType) -> String, tunnelBundleIdentifier: @escaping (VPNProtocolType) -> String,
vpn: NetworkExtensionVPN, vpn: VPNType,
dataCountInterval: TimeInterval = 3.0 dataCountInterval: TimeInterval = 3.0
) { ) {
self.appGroup = appGroup self.appGroup = appGroup