Reachability.swift icon indicating copy to clipboard operation
Reachability.swift copied to clipboard

whenReachable called for both wifi going on and off

Open alexhunsley opened this issue 6 years ago • 2 comments
trafficstars

When using the following setup:

    reachability.whenReachable = { reachability in
            print("reachable called")
        }
    }
    reachability.whenUnreachable = { reachability in
            print("UNreachable called")
        }
    }

I get the first block getting called for both wifi going on and off. The unreachable block never gets called. I've stepped in with the debugger to confirm this.

alexhunsley avatar Mar 13 '19 17:03 alexhunsley

Same issue here. Tested on iPhone SE, iOS 13.3

iharandreyev avatar Jan 09 '20 10:01 iharandreyev

Ah, my bad. I had cellular enabled.

iharandreyev avatar Jan 09 '20 10:01 iharandreyev