SwiftQueue icon indicating copy to clipboard operation
SwiftQueue copied to clipboard

Fixed multiple calls to operation.run() by network monitor when turning airplane mode off.

Open STomperi opened this issue 4 months ago • 1 comments

There was a memory retain cycle that was fixed by making monitor and operation weak and using dispatchQueue.async. Even with retain cycle fixed when networkType == .cellular, turning airplane off causes two satisfied network condition calls for both cellular and WiFi. Checking if pathUpdateHandler is nil prevents both of them triggering.

STomperi avatar Oct 07 '24 12:10 STomperi