aboutsummaryrefslogtreecommitdiffstats
path: root/WireGuard/Shared/Model/TunnelConfiguration.swift
diff options
context:
space:
mode:
Diffstat (limited to 'WireGuard/Shared/Model/TunnelConfiguration.swift')
-rw-r--r--WireGuard/Shared/Model/TunnelConfiguration.swift8
1 files changed, 8 insertions, 0 deletions
diff --git a/WireGuard/Shared/Model/TunnelConfiguration.swift b/WireGuard/Shared/Model/TunnelConfiguration.swift
index bee3c9dc..532212e5 100644
--- a/WireGuard/Shared/Model/TunnelConfiguration.swift
+++ b/WireGuard/Shared/Model/TunnelConfiguration.swift
@@ -22,3 +22,11 @@ final class TunnelConfiguration {
}
}
}
+
+extension TunnelConfiguration: Equatable {
+ static func == (lhs: TunnelConfiguration, rhs: TunnelConfiguration) -> Bool {
+ return lhs.name == rhs.name &&
+ lhs.interface == rhs.interface &&
+ Set(lhs.peers) == Set(rhs.peers)
+ }
+}