tunnelProviderManager.saveToPreferences { [weak self] error in
if let error = error {
- //TODO: the passwordReference for the old one has already been removed at this point and we can't easily roll back!
+ // TODO: the passwordReference for the old one has already been removed at this point and we can't easily roll back!
wg_log(.error, message: "Modify: Saving configuration failed: \(error)")
completionHandler(TunnelsManagerError.systemErrorOnModifyTunnel(systemError: error))
return
}
func dequeueReusableCell<T: UITableViewCell>(for indexPath: IndexPath) -> T {
- //swiftlint:disable:next force_cast
+ // swiftlint:disable:next force_cast
return dequeueReusableCell(withIdentifier: T.reuseIdentifier, for: indexPath) as! T
}
}
let removedSectionIndices = self.deletePeer(peer: peerData)
let shouldShowExcludePrivateIPs = (self.tunnelViewModel.peersData.count == 1 && self.tunnelViewModel.peersData[0].shouldAllowExcludePrivateIPsControl)
- //swiftlint:disable:next trailing_closure
+ // swiftlint:disable:next trailing_closure
tableView.performBatchUpdates({
self.tableView.deleteSections(removedSectionIndices, with: .fade)
if shouldShowExcludePrivateIPs {
class Application: NSApplication {
- private var appDelegate: AppDelegate? //swiftlint:disable:this weak_delegate
+ private var appDelegate: AppDelegate? // swiftlint:disable:this weak_delegate
override init() {
super.init()
func dequeueReusableCell<T: NSView>() -> T {
let identifier = NSUserInterfaceItemIdentifier(NSStringFromClass(T.self))
if let cellView = makeView(withIdentifier: identifier, owner: self) {
- //swiftlint:disable:next force_cast
+ // swiftlint:disable:next force_cast
return cellView as! T
}
let cellView = T()
private(set) var hasError = false
private(set) var privateKeyString: String?
- private(set) var hasOnePeer: Bool = false
+ private(set) var hasOnePeer = false
private(set) var lastOnePeerAllowedIPs = [String]()
private(set) var lastOnePeerDNSServers = [String]()
private(set) var lastOnePeerHasPublicKey = false
private let confTextStorage = ConfTextStorage()
- @objc dynamic var hasError: Bool = false
+ @objc dynamic var hasError = false
@objc dynamic var privateKeyString: String?
@objc dynamic var singlePeerAllowedIPs: [String]?