diff --git a/Sources/TunnelKitCore/Endpoint.swift b/Sources/TunnelKitCore/Endpoint.swift index eac597d..0261b06 100644 --- a/Sources/TunnelKitCore/Endpoint.swift +++ b/Sources/TunnelKitCore/Endpoint.swift @@ -88,13 +88,13 @@ public struct Endpoint: RawRepresentable, Codable, Equatable, CustomStringConver } public var rawValue: String { - return "\(address):\(proto.socketType.rawValue):\(proto.port)" + "\(address):\(proto.socketType.rawValue):\(proto.port)" } // MARK: CustomStringConvertible public var description: String { - return "\(address.maskedDescription):\(proto.rawValue)" + "\(address.maskedDescription):\(proto.rawValue)" } } @@ -107,7 +107,7 @@ public struct EndpointProtocol: RawRepresentable, Equatable, CustomStringConvert /// The remote port. public let port: UInt16 - public init(_ socketType: SocketType, _ port: UInt16) { + public init(_ socketType: SocketType, _ port: UInt16) { self.socketType = socketType self.port = port } @@ -129,13 +129,13 @@ public struct EndpointProtocol: RawRepresentable, Equatable, CustomStringConvert } public var rawValue: String { - return "\(socketType.rawValue):\(port)" + "\(socketType.rawValue):\(port)" } // MARK: CustomStringConvertible public var description: String { - return rawValue + rawValue } } diff --git a/Sources/TunnelKitCore/IPv4Settings.swift b/Sources/TunnelKitCore/IPv4Settings.swift index 0bd859b..b3eb636 100644 --- a/Sources/TunnelKitCore/IPv4Settings.swift +++ b/Sources/TunnelKitCore/IPv4Settings.swift @@ -49,7 +49,7 @@ public struct IPv4Settings: Codable, Equatable, CustomStringConvertible { // MARK: CustomStringConvertible public var description: String { - "{\(destination.maskedDescription)/\(mask) \(gateway?.maskedDescription ?? "*")}" + "{\(destination)/\(mask) \(gateway?.description ?? "*")}" } } @@ -84,6 +84,6 @@ public struct IPv4Settings: Codable, Equatable, CustomStringConvertible { // MARK: CustomStringConvertible public var description: String { - "addr \(address.maskedDescription) netmask \(addressMask) gw \(defaultGateway.maskedDescription)" + "addr \(address) netmask \(addressMask) gw \(defaultGateway)" } } diff --git a/Sources/TunnelKitCore/IPv6Settings.swift b/Sources/TunnelKitCore/IPv6Settings.swift index d9c6cda..14dc5b6 100644 --- a/Sources/TunnelKitCore/IPv6Settings.swift +++ b/Sources/TunnelKitCore/IPv6Settings.swift @@ -84,6 +84,6 @@ public struct IPv6Settings: Codable, Equatable, CustomStringConvertible { // MARK: CustomStringConvertible public var description: String { - "addr \(address.maskedDescription)/\(addressPrefixLength) gw \(defaultGateway.maskedDescription)" + "addr \(address)/\(addressPrefixLength) gw \(defaultGateway)" } } diff --git a/Sources/TunnelKitOpenVPNAppExtension/ResolvedRemote.swift b/Sources/TunnelKitOpenVPNAppExtension/ResolvedRemote.swift index d315059..ad5c397 100644 --- a/Sources/TunnelKitOpenVPNAppExtension/ResolvedRemote.swift +++ b/Sources/TunnelKitOpenVPNAppExtension/ResolvedRemote.swift @@ -91,7 +91,7 @@ class ResolvedRemote: CustomStringConvertible { // MARK: CustomStringConvertible var description: String { - return "{\(originalEndpoint.maskedDescription), resolved: \(resolvedEndpoints.maskedDescription)}" + "{\(originalEndpoint.maskedDescription), resolved: \(resolvedEndpoints.maskedDescription)}" } }