As far as I know this API works as specified. I recommend that you do the following:
-
Create a small test project with a single button that calls this API and prints the results.
-
Build, run, and test it on a device.
Does that reproduce the problem? If so:
-
What version of Xcode are you building with?
-
What version of iOS are you testing on?
-
What’s the expected result? That is, what’s the security type of the network that iOS is associated with?
-
Are you sure that the +fetchCurrentWithCompletionHandler:
call succeeded? If it fails, it calls the completion handler with nil
and it’s easy to go from there to a zero security type (with Objective-C).
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"