File tree Expand file tree Collapse file tree 1 file changed +0
-27
lines changed Expand file tree Collapse file tree 1 file changed +0
-27
lines changed Original file line number Diff line number Diff line change 88import ConcurrencyExtras
99import Foundation
1010import Helpers
11- import Network
1211
1312#if canImport(FoundationNetworking)
1413 import FoundationNetworking
@@ -493,29 +492,3 @@ public final class RealtimeClientV2: Sendable {
493492 url. appendingPathComponent ( " api/broadcast " )
494493 }
495494}
496-
497- final class NetworkMonitor : @unchecked Sendable {
498- static let shared = NetworkMonitor ( )
499-
500- private let monitor : NWPathMonitor
501- private let queue = DispatchQueue ( label: " NetworkMonitor " )
502-
503- private( set) var isConnected : Bool = false
504-
505- private init ( ) {
506- monitor = NWPathMonitor ( )
507- }
508-
509- func start( _ onChange: ( @Sendable ( ) -> Void ) ? = nil ) {
510- monitor. pathUpdateHandler = { [ weak self] path in
511- self ? . isConnected = path. status != . unsatisfied
512- onChange ? ( )
513- }
514-
515- monitor. start ( queue: queue)
516- }
517-
518- func stop( ) {
519- monitor. cancel ( )
520- }
521- }
You can’t perform that action at this time.
0 commit comments