CNContactViewController Image Always Blank with Empty String Phone Number

Originator:spencerbakermail
Number:rdar://33542935 Date Originated:July 26 2017
Status:Open Resolved:
Product:iOS + SDK Product Version:10.3.1 (14E8301)
Classification:UI/Usability Reproducible:Always
 
Area:
Contacts Framework

Summary:
When you create a CNContactViewController for a new contact, if the CNMutableContact has image data and an empty string for any phone number, the image will not render.
The image will render a gray gradient instead.

Note: when you save the new contact, the image saves correctly; it does not save as a gray gradient image.

Steps to Reproduce:
Create a CNMutableContact with the following:
- Valid imageData
- a Phone number, CNLabelPhoneNumberMobile perferrably, with an empty string as the value.

Pass the newly created CNMutableContact into a CNContactViewController using the CNContactViewController(forNewContact: _) init method. Present the created CNContactViewController and view the image.

The image will be a gray gradient instead of the set image for imageData.

Expected Results:
The image renders correctly even when a phone number is set to an empty string.

Observed Results:
Image renders as a gray gradient.

Version:
10.3.1 (14E8301)

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!