diff options
author | Roopesh Chander <roop@roopc.net> | 2018-11-10 12:25:17 +0530 |
---|---|---|
committer | Roopesh Chander <roop@roopc.net> | 2018-11-10 16:44:28 +0530 |
commit | 8e7bfb15ed5c2a4537c18ef512a87d7a73ac9253 (patch) | |
tree | 06185f41f4aae38e1400710cb6e5b6680f872d62 /WireGuard/WireGuard/UI/iOS | |
parent | VPN: There are no DNS errors to handle in the app now (diff) | |
download | wireguard-apple-8e7bfb15ed5c2a4537c18ef512a87d7a73ac9253.tar.xz wireguard-apple-8e7bfb15ed5c2a4537c18ef512a87d7a73ac9253.zip |
TunnelsManager: startDeactivation() need not take a completion handler
Because the completion handler pattern doesn't fit in this case.
Signed-off-by: Roopesh Chander <roop@roopc.net>
Diffstat (limited to 'WireGuard/WireGuard/UI/iOS')
-rw-r--r-- | WireGuard/WireGuard/UI/iOS/TunnelDetailTableViewController.swift | 4 | ||||
-rw-r--r-- | WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift | 4 |
2 files changed, 2 insertions, 6 deletions
diff --git a/WireGuard/WireGuard/UI/iOS/TunnelDetailTableViewController.swift b/WireGuard/WireGuard/UI/iOS/TunnelDetailTableViewController.swift index 76a38e3..5209b3a 100644 --- a/WireGuard/WireGuard/UI/iOS/TunnelDetailTableViewController.swift +++ b/WireGuard/WireGuard/UI/iOS/TunnelDetailTableViewController.swift @@ -159,9 +159,7 @@ extension TunnelDetailTableViewController { } } } else { - s.tunnelsManager.startDeactivation(of: s.tunnel) { error in - print("Error while deactivating: \(String(describing: error))") - } + s.tunnelsManager.startDeactivation(of: s.tunnel) } } return cell diff --git a/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift b/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift index a9d858e..ba61743 100644 --- a/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift +++ b/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift @@ -287,9 +287,7 @@ extension TunnelsListTableViewController: UITableViewDataSource { } } } else { - tunnelsManager.startDeactivation(of: tunnel) { [weak s] error in - s?.showErrorAlert(title: "Deactivation error", message: "Error while bringing down tunnel: \(String(describing: error))") - } + tunnelsManager.startDeactivation(of: tunnel) } } } |