From 8a916beb389f84e21ed1aaf0d246801cd6acd73c Mon Sep 17 00:00:00 2001 From: Eric Kuck Date: Wed, 12 Dec 2018 21:09:52 -0600 Subject: More formatting nits and cyclomatic complexity fixes Signed-off-by: Eric Kuck --- WireGuard/WireGuard/ZipArchive/ZipExporter.swift | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'WireGuard/WireGuard/ZipArchive/ZipExporter.swift') diff --git a/WireGuard/WireGuard/ZipArchive/ZipExporter.swift b/WireGuard/WireGuard/ZipArchive/ZipExporter.swift index b0e6b15..cdc9ac9 100644 --- a/WireGuard/WireGuard/ZipArchive/ZipExporter.swift +++ b/WireGuard/WireGuard/ZipArchive/ZipExporter.swift @@ -6,7 +6,7 @@ import UIKit enum ZipExporterError: WireGuardAppError { case noTunnelsToExport - func alertText() -> (String, String)? { + func alertText() -> AlertText { switch self { case .noTunnelsToExport: return ("Nothing to export", "There are no tunnels to export") @@ -15,8 +15,7 @@ enum ZipExporterError: WireGuardAppError { } class ZipExporter { - static func exportConfigFiles(tunnelConfigurations: [TunnelConfiguration], to url: URL, - completion: @escaping (WireGuardAppError?) -> Void) { + static func exportConfigFiles(tunnelConfigurations: [TunnelConfiguration], to url: URL, completion: @escaping (WireGuardAppError?) -> Void) { guard !tunnelConfigurations.isEmpty else { completion(ZipExporterError.noTunnelsToExport) -- cgit v1.2.3-59-g8ed1b