Get user's own contact card with unifiedMeContactWithKeys(toFetch:)

Hi everyone!

It came to my knowledge from the documentation (https://developer.apple.com/documentation/contacts/cncontactstore/unifiedmecontactwithkeys%28tofetch:%29) that the method unifiedMeContactWithKeys(toFetch:), which fetches the me-card in the phone book by using CNContactStore, was recently made available for iOS as well. The problem is that I regardless get the error saying the method is unavailable for iOS, even though the documentation clearly states it should be available. I have tried several Xcode version including the latest one but to no avail... Does anyone have any idea what is wrong here?

Kindest regards, Andreas

The unifiedMeContactWithKeys(toFetch:) instance method is unavailable on iOS, watchOS, and visionOS. The Objective-C section of its documentation display the correct platforms on which this API is available.

Get user's own contact card with unifiedMeContactWithKeys(toFetch:)
 
 
Q