Drop deprecated configuration values
- debugLogKey - lastErrorKey
This commit is contained in:
parent
12e0a55f7a
commit
9726158030
|
@ -49,8 +49,6 @@ class AppConstants {
|
|||
// builder.debugLogFormat = "$Dyyyy-MM-dd HH:mm:ss.SSS$d $L $N.$F:$l - $M"
|
||||
// builder.debugLogFormat = "$DHH:mm:ss$d $N.$F:$l - $M"
|
||||
builder.debugLogFormat = Log.debugFormat
|
||||
builder.debugLogKey = "LastVPNLog"
|
||||
builder.lastErrorKey = "LastVPNError"
|
||||
return builder.build()
|
||||
}
|
||||
|
||||
|
|
|
@ -280,20 +280,11 @@ class ConnectionService: Codable {
|
|||
}
|
||||
|
||||
var vpnLastError: TunnelKitProvider.ProviderError? {
|
||||
guard let key = baseConfiguration.lastErrorKey else {
|
||||
return nil
|
||||
}
|
||||
guard let rawValue = defaults.string(forKey: key) else {
|
||||
return nil
|
||||
}
|
||||
return TunnelKitProvider.ProviderError(rawValue: rawValue)
|
||||
return baseConfiguration.lastError(in: appGroup)
|
||||
}
|
||||
|
||||
func clearVpnLastError() {
|
||||
guard let key = baseConfiguration.lastErrorKey else {
|
||||
return
|
||||
}
|
||||
defaults.removeObject(forKey: key)
|
||||
baseConfiguration.clearLastError(in: appGroup)
|
||||
}
|
||||
|
||||
// func eraseVpnLog() {
|
||||
|
|
|
@ -60,8 +60,6 @@ class HostConnectionProfile: ConnectionProfile, Codable, Equatable {
|
|||
builder.mtu = configuration.mtu
|
||||
builder.shouldDebug = configuration.shouldDebug
|
||||
builder.debugLogFormat = configuration.debugLogFormat
|
||||
builder.debugLogKey = configuration.debugLogKey
|
||||
builder.lastErrorKey = configuration.lastErrorKey
|
||||
|
||||
return builder.build()
|
||||
}
|
||||
|
|
|
@ -120,8 +120,6 @@ class ProviderConnectionProfile: ConnectionProfile, Codable, Equatable {
|
|||
builder.mtu = configuration.mtu
|
||||
builder.shouldDebug = configuration.shouldDebug
|
||||
builder.debugLogFormat = configuration.debugLogFormat
|
||||
builder.debugLogKey = configuration.debugLogKey
|
||||
builder.lastErrorKey = configuration.lastErrorKey
|
||||
|
||||
if let address = manualAddress {
|
||||
builder.prefersResolvedAddresses = true
|
||||
|
|
Loading…
Reference in New Issue