diff options
author | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-12-21 23:34:56 +0100 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2018-12-21 23:34:56 +0100 |
commit | 7b9d4cb9e35a88f13face71543ce4773102fe224 (patch) | |
tree | 90810e67570a1bd2b520f352b50117925d3b1fab /WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift | |
parent | providerConfiguration is now a WgQuickConfig (diff) | |
download | wireguard-apple-7b9d4cb9e35a88f13face71543ce4773102fe224.tar.xz wireguard-apple-7b9d4cb9e35a88f13face71543ce4773102fe224.zip |
Nuke trailing spaces
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift')
-rw-r--r-- | WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift b/WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift index 8378311..187f7fd 100644 --- a/WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift +++ b/WireGuard/WireGuard/UI/iOS/ViewController/TunnelDetailTableViewController.swift @@ -43,7 +43,7 @@ class TunnelDetailTableViewController: UITableViewController { required init?(coder aDecoder: NSCoder) { fatalError("init(coder:) has not been implemented") } - + deinit { onDemandStatusObservationToken = nil statusObservationToken = nil @@ -166,7 +166,7 @@ extension TunnelDetailTableViewController { private func statusCell(for tableView: UITableView, at indexPath: IndexPath) -> UITableViewCell { let cell: SwitchCell = tableView.dequeueReusableCell(for: indexPath) - + let statusUpdate: (SwitchCell, TunnelStatus) -> Void = { cell, status in let text: String switch status { @@ -192,13 +192,13 @@ extension TunnelDetailTableViewController { } cell.isEnabled = status == .active || status == .inactive } - + statusUpdate(cell, tunnel.status) statusObservationToken = tunnel.observe(\.status) { [weak cell] tunnel, _ in guard let cell = cell else { return } statusUpdate(cell, tunnel.status) } - + cell.onSwitchToggled = { [weak self] isOn in guard let self = self else { return } if isOn { |