diff options
author | Roopesh Chander <roop@roopc.net> | 2018-12-13 18:55:20 +0530 |
---|---|---|
committer | Roopesh Chander <roop@roopc.net> | 2018-12-13 18:56:07 +0530 |
commit | bf58159d996ba257673cd37e1756c8ddcf060634 (patch) | |
tree | 68cc4228a4cc468a390866fdbd50b32653c08dfd /WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift | |
parent | Logging: Write versions from both app and extension (diff) | |
download | wireguard-apple-bf58159d996ba257673cd37e1756c8ddcf060634.tar.xz wireguard-apple-bf58159d996ba257673cd37e1756c8ddcf060634.zip |
TunnelsManager: Report activation errors through the activationDelegate
Don't report activation errors through completion handlers
Signed-off-by: Roopesh Chander <roop@roopc.net>
Diffstat (limited to 'WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift')
-rw-r--r-- | WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift b/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift index f24b452..efa85e6 100644 --- a/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift +++ b/WireGuard/WireGuard/UI/iOS/TunnelsListTableViewController.swift @@ -248,15 +248,7 @@ extension TunnelsListTableViewController: UITableViewDataSource { cell.onSwitchToggled = { [weak self] isOn in guard let self = self, let tunnelsManager = self.tunnelsManager else { return } if isOn { - tunnelsManager.startActivation(of: tunnel) { [weak self] error in - if let error = error { - ErrorPresenter.showErrorAlert(error: error, from: self) { - DispatchQueue.main.async { - cell.statusSwitch.isOn = false - } - } - } - } + tunnelsManager.startActivation(of: tunnel) } else { tunnelsManager.startDeactivation(of: tunnel) } |