aboutsummaryrefslogtreecommitdiffstats
path: root/WireGuard/WireGuard/UI/TunnelViewModel.swift
diff options
context:
space:
mode:
Diffstat (limited to 'WireGuard/WireGuard/UI/TunnelViewModel.swift')
-rw-r--r--WireGuard/WireGuard/UI/TunnelViewModel.swift4
1 files changed, 1 insertions, 3 deletions
diff --git a/WireGuard/WireGuard/UI/TunnelViewModel.swift b/WireGuard/WireGuard/UI/TunnelViewModel.swift
index 35dd98ba..efca5c0f 100644
--- a/WireGuard/WireGuard/UI/TunnelViewModel.swift
+++ b/WireGuard/WireGuard/UI/TunnelViewModel.swift
@@ -3,7 +3,6 @@
import Foundation
-//swiftlint:disable:next type_body_length
class TunnelViewModel {
enum InterfaceField: CaseIterable {
@@ -74,6 +73,7 @@ class TunnelViewModel {
case removed
case modified
}
+
var interfaceChanged: ([InterfaceField: FieldChange]) -> Void
var peerChangedAt: (Int, [PeerField: FieldChange]) -> Void
var peersRemovedAt: ([Int]) -> Void
@@ -141,7 +141,6 @@ class TunnelViewModel {
return scratchpad
}
- //swiftlint:disable:next cyclomatic_complexity function_body_length
func save() -> SaveResult<(String, InterfaceConfiguration)> {
if let config = validatedConfiguration, let name = validatedName {
return .saved((name, config))
@@ -327,7 +326,6 @@ class TunnelViewModel {
return scratchpad
}
- //swiftlint:disable:next cyclomatic_complexity
func save() -> SaveResult<PeerConfiguration> {
if let validatedConfiguration = validatedConfiguration {
return .saved(validatedConfiguration)