Fix macOS toggle style

This commit is contained in:
世界 committed 2024-09-16 14:22:36 +08:00
1 parent 66a33e3398
commit a8ea162606
6 files changed
+77 -131

No files matched your search

@@ -75,10 +75,9 @@
private func reset() {
selected = false
profiles = nil
if let connection = connection {
if let connection {
connection.cancel()
self.connection = nil
}
}
@@ -87,7 +86,7 @@
self.connection = NWSocket(connection)
connection.stateUpdateHandler = { state in
switch state {
case .failed(let error):
case let .failed(error):
DispatchQueue.main.async { [self] in
reset()
alert = Alert(error)