aboutsummaryrefslogtreecommitdiffstats
path: root/WireGuard/Shared/Model/DNSServer.swift
diff options
context:
space:
mode:
authorEric Kuck <eric@bluelinelabs.com>2018-12-21 22:41:54 -0600
committerEric Kuck <eric@bluelinelabs.com>2018-12-21 22:57:17 -0600
commit0bec5b04b0b76fef7eeafc6609ffa05c61117df8 (patch)
tree25792a2b8448d529867fd4a8f9370dddf258177a /WireGuard/Shared/Model/DNSServer.swift
parentClean up trailing whitespace (diff)
downloadwireguard-apple-0bec5b04b0b76fef7eeafc6609ffa05c61117df8.tar.xz
wireguard-apple-0bec5b04b0b76fef7eeafc6609ffa05c61117df8.zip
All models now Equatable
Signed-off-by: Eric Kuck <eric@bluelinelabs.com>
Diffstat (limited to 'WireGuard/Shared/Model/DNSServer.swift')
-rw-r--r--WireGuard/Shared/Model/DNSServer.swift6
1 files changed, 6 insertions, 0 deletions
diff --git a/WireGuard/Shared/Model/DNSServer.swift b/WireGuard/Shared/Model/DNSServer.swift
index 710c656c..5a509cba 100644
--- a/WireGuard/Shared/Model/DNSServer.swift
+++ b/WireGuard/Shared/Model/DNSServer.swift
@@ -12,6 +12,12 @@ struct DNSServer {
}
}
+extension DNSServer: Equatable {
+ static func == (lhs: DNSServer, rhs: DNSServer) -> Bool {
+ return lhs.address.rawValue == rhs.address.rawValue
+ }
+}
+
extension DNSServer {
var stringRepresentation: String {
return "\(address)"